Skip to content

armgit / ente

Public Imported from GitHub
0

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

[mobile][locker] fix camera permission glitch in scanner page

aaqil69641b164404
diff --git a/mobile/apps/locker/lib/ui/pages/scanner/scanner_capture_page.dart b/mobile/apps/locker/lib/ui/pages/scanner/scanner_capture_page.dart
index 2799445fcc..43425c4a14 100644
--- a/mobile/apps/locker/lib/ui/pages/scanner/scanner_capture_page.dart
+++ b/mobile/apps/locker/lib/ui/pages/scanner/scanner_capture_page.dart
@@ -109,9 +109,7 @@ class _ScannerCapturePageState extends State<ScannerCapturePage>
}
_autoCapture.reset();
} else if (state == AppLifecycleState.resumed) {
- if (!_reviewActive &&
- _camera == null &&
- _status != _CameraStatus.starting) {
+ if (!_reviewActive && _camera == null && _status == _CameraStatus.ready) {
unawaited(_startCamera());
}
}