getContact method

  1. @override
ChatwootContact? getContact()
override

Implementation

@override
ChatwootContact? getContact() {
  if (_box.values.length == 0) {
    return null;
  }

  final contactIdentifier =
      _clientInstanceIdToContactIdentifierBox.get(_clientInstanceKey);

  if (contactIdentifier == null) {
    return null;
  }

  return _box.get(contactIdentifier, defaultValue: null);
}