add method

  1. @override
Future<ChatResult<void>> add(
  1. String contactUserId
)
override

Adds a user to the contact list.

One-sided: adding does NOT create a reciprocal entry on the other user. Idempotent — adding an already-present contact returns success. Backend emits contact_added so the contact appears on the user's other devices.

Implementation

@override
Future<ChatResult<void>> add(String contactUserId) async {
  _client._contacts.add(contactUserId);
  return const ChatSuccess(null);
}