fix oauth flow

This commit is contained in:
Sanidhya Kumar Verma
2024-09-04 11:53:27 +00:00
committed by GitHub
parent 1f0ecd696d
commit 04694246c0
4 changed files with 51 additions and 14 deletions
+3 -5
View File
@@ -17,15 +17,13 @@ export const tokenCache = {
async getToken(key: string) {
try {
const item = await SecureStore.getItemAsync(key);
if (item) {
console.log(`${key} was used 🔐 \n`);
} else {
console.log("No values stored under key: " + key);
}
return item;
} catch (error) {
console.error("GET_TOKEN_CACHE: ", error);
await SecureStore.deleteItemAsync(key);
return null;
}
},