fix: Fixed dispose errors

This commit is contained in:
Deven Joshi
2020-11-23 15:46:38 +05:30
parent b0b05e165c
commit 0ba45d82be
4 changed files with 11 additions and 2 deletions
+8 -1
View File
@@ -127,7 +127,6 @@ class _ReactionPickerState extends State<ReactionPicker>
void pop() async {
for (var a in animations) {
a.stop();
//a.dispose();
}
Navigator.of(context).pop();
}
@@ -145,4 +144,12 @@ class _ReactionPickerState extends State<ReactionPicker>
StreamChannel.of(context).channel.deleteReaction(widget.message, reaction);
pop();
}
@override
void dispose() {
for (var a in animations) {
a?.dispose();
}
super.dispose();
}
}