getChatTime method

String getChatTime(
  1. BuildContext context,
  2. int? epochTime
)

Implementation

String getChatTime(BuildContext context, int? epochTime) {
  if (epochTime == null) return Constants.emptyString;
  if (epochTime == 0) return Constants.emptyString;
  var convertedTime = epochTime;
  var hourTime = manipulateMessageTime(
      context, DateTime.fromMicrosecondsSinceEpoch(convertedTime));
  calendar = DateTime.fromMicrosecondsSinceEpoch(convertedTime);
  return hourTime;
}