mirror of
https://gitlab.com/famedly/fluffychat.git
synced 2024-11-19 18:49:28 +01:00
11 lines
328 B
Dart
11 lines
328 B
Dart
import 'package:famedlysdk/famedlysdk.dart';
|
|
|
|
extension ClientPresenceExtension on Client {
|
|
static final Map<String, Profile> presencesCache = {};
|
|
|
|
Future<Profile> requestProfileCached(String senderId) async {
|
|
presencesCache[senderId] ??= await getProfileFromUserId(senderId);
|
|
return presencesCache[senderId];
|
|
}
|
|
}
|