fix oauth flow
This commit is contained in:
committed by
GitHub
parent
1f0ecd696d
commit
04694246c0
+3
-5
@@ -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;
|
||||
}
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user