From 501a6cd72f1c3b83a75a1368372502f8539741b0 Mon Sep 17 00:00:00 2001 From: Justin Date: Fri, 2 Jul 2021 15:49:55 -0500 Subject: [PATCH] Refactor resetPinAttempts --- app/utils/storage/secureStorage.ts | 11 +---------- 1 file changed, 1 insertion(+), 10 deletions(-) diff --git a/app/utils/storage/secureStorage.ts b/app/utils/storage/secureStorage.ts index 6beb3d3f2f..9019d77d94 100644 --- a/app/utils/storage/secureStorage.ts +++ b/app/utils/storage/secureStorage.ts @@ -97,16 +97,7 @@ export default class KeyStoreWrapper { } public static async resetPinAttempts() : Promise { - try { - await RNSecureKeyStore.set( - KeyStoreWrapper.PIN_ATTEMPTS, - "0", - { accessible: ACCESSIBLE.ALWAYS_THIS_DEVICE_ONLY } - ) - return true - } catch { - return false - } + return await KeyStoreWrapper.setPinAttempts("0") } public static async removePinAttempts() : Promise {