@umituz/react-native-auth 1.7.0 → 1.7.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@umituz/react-native-auth",
|
|
3
|
-
"version": "1.7.
|
|
3
|
+
"version": "1.7.1",
|
|
4
4
|
"description": "Authentication service for React Native apps - Secure, type-safe, and production-ready. Provider-agnostic design supports Firebase Auth and can be adapted for Supabase or other providers.",
|
|
5
5
|
"main": "./src/index.ts",
|
|
6
6
|
"types": "./src/index.ts",
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
* Single Responsibility: Manage guest mode persistence
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
|
-
import { storageRepository } from "@umituz/react-native-storage";
|
|
6
|
+
import { storageRepository, unwrap } from "@umituz/react-native-storage";
|
|
7
7
|
|
|
8
8
|
const GUEST_MODE_KEY = "@auth_guest_mode";
|
|
9
9
|
|
|
@@ -12,7 +12,8 @@ const GUEST_MODE_KEY = "@auth_guest_mode";
|
|
|
12
12
|
*/
|
|
13
13
|
export async function loadGuestMode(): Promise<boolean> {
|
|
14
14
|
try {
|
|
15
|
-
const
|
|
15
|
+
const result = await storageRepository.getString(GUEST_MODE_KEY, "false");
|
|
16
|
+
const guestModeValue = unwrap(result, "false");
|
|
16
17
|
return guestModeValue === "true";
|
|
17
18
|
} catch {
|
|
18
19
|
return false;
|