From e6a20b5a1674b6af25121fafaefffa55d5557342 Mon Sep 17 00:00:00 2001 From: Kingkor Roy Tirtho Date: Mon, 26 Feb 2024 10:05:50 +0600 Subject: [PATCH] chore: fix add null check before accessing auth cookie from hive box #1264 --- lib/collections/routes.dart | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/collections/routes.dart b/lib/collections/routes.dart index 7b0d836d..43d0cf2e 100644 --- a/lib/collections/routes.dart +++ b/lib/collections/routes.dart @@ -50,7 +50,7 @@ final routerProvider = Provider((ref) { ref.read(AuthenticationNotifier.provider.notifier); final json = await authNotifier.box.get(authNotifier.cacheKey); - if (json["cookie"] == null && + if (json?["cookie"] == null && !KVStoreService.doneGettingStarted) { return "/getting-started"; }