formatMessageStatus static method

String formatMessageStatus(
  1. String status
)

Formats the display of message status

Implementation

static String formatMessageStatus(String status) {
  switch (status) {
    case 'sent':
      return 'Sent';
    case 'delivered':
      return 'Delivered';
    case 'read':
      return 'Read';
    default:
      return status;
  }
}