fix: Compare groups

This commit is contained in:
PapaTutuWawa 2023-01-07 19:58:46 +01:00
parent 41560682a1
commit 09d2601e85
2 changed files with 4 additions and 3 deletions

View File

@ -1,4 +1,5 @@
import 'dart:async';
import 'package:collection/collection.dart';
import 'package:meta/meta.dart';
import 'package:moxxmpp/src/jid.dart';
import 'package:moxxmpp/src/managers/attributes.dart';
@ -26,13 +27,12 @@ class XmppRosterItem {
@override
bool operator==(Object other) {
// TODO(PapaTutuWawa): Implement the groups
return other is XmppRosterItem &&
other.jid == jid &&
other.name == name &&
other.subscription == subscription &&
other.ask == ask; /*&&
other.groups == groups;*/
other.ask == ask &&
const ListEquality<String>().equals(other.groups, groups);
}
@override

View File

@ -8,6 +8,7 @@ environment:
sdk: '>=2.17.5 <3.0.0'
dependencies:
collection: ^1.17.0
cryptography: ^2.0.5
freezed: ^2.1.0+1
freezed_annotation: ^2.1.0