setTyping method

  1. @override
Future<void> setTyping(
  1. String userId,
  2. String roomId,
  3. bool typing, {
  4. int? timeout,
})

Sends a typing notification and initiates a megolm session, if needed

Implementation

@override
Future<void> setTyping(
  String userId,
  String roomId,
  bool typing, {
  int? timeout,
}) async {
  await super.setTyping(userId, roomId, typing, timeout: timeout);
  final room = getRoomById(roomId);
  if (typing && room != null && encryptionEnabled && room.encrypted) {
    // ignore: unawaited_futures
    encryption?.keyManager.prepareOutboundGroupSession(roomId);
  }
}