diff --git a/lib/ui/routes/account_settings/account_image_settings.dart b/lib/ui/routes/account_settings/account_image_settings.dart index f59a38d..ee03e02 100644 --- a/lib/ui/routes/account_settings/account_image_settings.dart +++ b/lib/ui/routes/account_settings/account_image_settings.dart @@ -1,7 +1,9 @@ +import 'package:comunic/helpers/database/users_database_helper.dart'; import 'package:comunic/helpers/settings_helper.dart'; import 'package:comunic/models/account_image_settings.dart'; import 'package:comunic/ui/widgets/async_screen_widget.dart'; import 'package:comunic/ui/widgets/network_image_widget.dart'; +import 'package:comunic/utils/account_utils.dart'; import 'package:comunic/utils/files_utils.dart'; import 'package:comunic/utils/intl_utils.dart'; import 'package:comunic/utils/ui_utils.dart'; @@ -37,6 +39,14 @@ class __AccountImageSettingsBodyState extends State<_AccountImageSettingsBody> { final _key = GlobalKey(); + @override + void dispose() { + // Remove current user information to force refresh of account image + UsersDatabaseHelper().delete(userID()); + + super.dispose(); + } + @override Widget build(BuildContext context) { return AsyncScreenWidget(