FurryChat/lib/utils/client_presence_extension.dart

12 lines
353 B
Dart
Raw Normal View History

import 'package:famedlysdk/famedlysdk.dart';
import 'presence_extension.dart';
extension ClientPresenceExtension on Client {
List<Presence> get statusList {
final statusList = presences.values.toList();
statusList.removeWhere((Presence p) => !p.isStatus);
statusList.sort((a, b) => b.time.compareTo(a.time));
return statusList;
}
}