Add logging for a bunch of silently swallowed errors (#7148)

This commit is contained in:
James Salter 2021-11-18 09:01:45 +11:00 committed by GitHub
parent 8b6778e1d3
commit e549438e2a
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 15 additions and 5 deletions

View file

@ -317,7 +317,9 @@ export default abstract class BasePlatform {
let data;
try {
data = await idbLoad("pickleKey", [userId, deviceId]);
} catch (e) {}
} catch (e) {
logger.error("idbLoad for pickleKey failed", e);
}
if (!data) {
return null;
}
@ -396,6 +398,8 @@ export default abstract class BasePlatform {
async destroyPickleKey(userId: string, deviceId: string): Promise<void> {
try {
await idbDelete("pickleKey", [userId, deviceId]);
} catch (e) {}
} catch (e) {
logger.error("idbDelete failed in destroyPickleKey", e);
}
}
}