chore: check if mounted before setting state in async function (#2194)
This commit is contained in:
parent
269af9f4e6
commit
c47c5cb2df
1 changed files with 1 additions and 3 deletions
|
|
@ -88,9 +88,7 @@ class ActivityListViewState extends State<ActivityListView> {
|
|||
},
|
||||
);
|
||||
} finally {
|
||||
setState(() {
|
||||
_isLoading = false;
|
||||
});
|
||||
if (mounted) setState(() => _isLoading = false);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue