Skip to content

Commit 9084a4e

Browse files
JacquesDIconicaFreek van de Ven
authored andcommitted
fix: pop loading dialog when loading finished for send forgot password request
1 parent a74281c commit 9084a4e

5 files changed

Lines changed: 18 additions & 14 deletions

File tree

CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
## 6.3.2
2+
3+
- Fixed infinite loading when closing the forgotPasswordSucces screen and ForgotPasswordUnsuccessfull screen.
4+
15
## 6.3.1
26

37
- Fixed a bug where the keyboard for the login username and password fields was closing because of a different LoginOptions.hashCode with the same LoginOptions values.

packages/firebase_user_repository/pubspec.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
name: firebase_user_repository
22
description: "firebase_user_repository for flutter_user package"
3-
version: 6.3.1
3+
version: 6.3.2
44
repository: https://github.com/Iconica-Development/flutter_user
55

66
publish_to: https://forgejo.internal.iconica.nl/api/packages/internal/pub
@@ -14,7 +14,7 @@ dependencies:
1414
sdk: flutter
1515
user_repository_interface:
1616
hosted: https://forgejo.internal.iconica.nl/api/packages/internal/pub/
17-
version: ^6.3.1
17+
version: ^6.3.2
1818
cloud_firestore: ^5.4.2
1919
firebase_auth: ^5.3.0
2020

packages/flutter_user/lib/src/flutter_user_navigator_userstory.dart

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -173,15 +173,15 @@ class _FlutterUserNavigatorUserstoryState
173173
var requestPasswordReponse =
174174
await userService!.requestChangePassword(email: email);
175175

176-
if (requestPasswordReponse.requestSuccesfull) {
177-
if (context.mounted) {
178-
await pushReplacement(_forgotPasswordSuccessScreen());
179-
}
180-
} else {
181-
if (context.mounted) {
182-
await push(_forgotPasswordUnsuccessfullScreen());
183-
}
176+
if (!mounted) return;
177+
Navigator.of(context).pop();
178+
179+
if (!requestPasswordReponse.requestSuccesfull) {
180+
await push(_forgotPasswordUnsuccessfullScreen());
181+
return;
184182
}
183+
184+
await pushReplacement(_forgotPasswordSuccessScreen());
185185
}
186186

187187
return ForgotPasswordForm(
@@ -272,7 +272,7 @@ class _FlutterUserNavigatorUserstoryState
272272

273273
Future<void> pushReplacement(Widget screen) async {
274274
if (!context.mounted) return;
275-
await Navigator.of(context).push(
275+
await Navigator.of(context).pushReplacement(
276276
MaterialPageRoute(
277277
builder: (context) => screen,
278278
),

packages/flutter_user/pubspec.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
name: flutter_user
22
description: "Flutter Userstory for onboarding, login, and registration."
3-
version: 6.3.1
3+
version: 6.3.2
44
repository: https://github.com/Iconica-Development/flutter_user
55

66
publish_to: https://forgejo.internal.iconica.nl/api/packages/internal/pub
@@ -22,7 +22,7 @@ dependencies:
2222
version: ^4.1.0
2323
user_repository_interface:
2424
hosted: https://forgejo.internal.iconica.nl/api/packages/internal/pub/
25-
version: ^6.3.1
25+
version: ^6.3.2
2626
flutter_accessibility:
2727
hosted: https://forgejo.internal.iconica.nl/api/packages/internal/pub
2828
version: ^0.0.3

packages/user_repository_interface/pubspec.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
name: user_repository_interface
22
description: "user_repository_interface for flutter_user package"
3-
version: 6.3.1
3+
version: 6.3.2
44
repository: https://github.com/Iconica-Development/flutter_user
55

66
publish_to: https://forgejo.internal.iconica.nl/api/packages/internal/pub

0 commit comments

Comments
 (0)