getMsgReadRecv method

int getMsgReadRecv(
  1. String contactName,
  2. String what
)

Get cached read/received/message count for the given contact.

Implementation

int getMsgReadRecv(String contactName, String what) {
  var cont = _contacts[contactName];
  if (cont != null) {
    switch (what) {
      case 'recv':
        return cont.recv ?? 0;
      case 'read':
        return cont.read ?? 0;
      case 'msg':
        return cont.seq ?? 0;
    }
  }
  return 0;
}