remove observer on dispose
This commit is contained in:
parent
25ef4203cb
commit
78fb56bb34
|
@ -86,6 +86,12 @@ class _EnteAppState extends State<EnteApp> with WidgetsBindingObserver {
|
|||
);
|
||||
}
|
||||
|
||||
@override
|
||||
void dispose() {
|
||||
WidgetsBinding.instance.removeObserver(this);
|
||||
super.dispose();
|
||||
}
|
||||
|
||||
@override
|
||||
void didChangeAppLifecycleState(AppLifecycleState state) {
|
||||
if (state == AppLifecycleState.resumed) {
|
||||
|
|
Loading…
Reference in a new issue