Skip to content

armgit / ente

Public Imported from GitHub
0

πŸ’š End-to-end encrypted cloud for everything.

[mob] Pop only when there's screen in stack

Neeraj Gupta85230b5123fe
diff --git a/mobile/lib/ui/growth/referral_screen.dart b/mobile/lib/ui/growth/referral_screen.dart
index d2897dd381..7e8cdef434 100644
--- a/mobile/lib/ui/growth/referral_screen.dart
+++ b/mobile/lib/ui/growth/referral_screen.dart
@@ -63,8 +63,12 @@ class _ReferralScreenState extends State<ReferralScreen> {
icon: Icons.close_outlined,
iconButtonType: IconButtonType.secondary,
onTap: () {
- Navigator.pop(context);
- Navigator.pop(context);
+ if (Navigator.canPop(context)) {
+ Navigator.pop(context);
+ }
+ if (Navigator.canPop(context)) {
+ Navigator.pop(context);
+ }
},
),
],