diff options
Diffstat (limited to 'src/electron/ipc-api/sessionStorage.ts')
-rw-r--r-- | src/electron/ipc-api/sessionStorage.ts | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/src/electron/ipc-api/sessionStorage.ts b/src/electron/ipc-api/sessionStorage.ts index 20f0ac9d2..96acacd12 100644 --- a/src/electron/ipc-api/sessionStorage.ts +++ b/src/electron/ipc-api/sessionStorage.ts | |||
@@ -2,7 +2,8 @@ import { ipcMain, Session, session } from 'electron'; | |||
2 | 2 | ||
3 | import { TODOS_PARTITION_ID } from '../../config'; | 3 | import { TODOS_PARTITION_ID } from '../../config'; |
4 | 4 | ||
5 | const debug = require('debug')('Ferdium:ipcApi:sessionStorage'); | 5 | // TODO: Go back to 'debug' from 'console.log' when https://github.com/electron/electron/issues/31689 is fixed |
6 | // const debug = require('debug')('Ferdium:ipcApi:sessionStorage'); | ||
6 | 7 | ||
7 | function deduceSession(serviceId: string | undefined | null): Session { | 8 | function deduceSession(serviceId: string | undefined | null): Session { |
8 | if (serviceId) { | 9 | if (serviceId) { |
@@ -21,14 +22,14 @@ export default async () => { | |||
21 | const serviceSession = deduceSession(serviceId); | 22 | const serviceSession = deduceSession(serviceId); |
22 | serviceSession.flushStorageData(); | 23 | serviceSession.flushStorageData(); |
23 | if (targetsToClear) { | 24 | if (targetsToClear) { |
24 | debug('Clearing targets:', targetsToClear); | 25 | console.log('Clearing targets:', targetsToClear); |
25 | serviceSession.clearStorageData(targetsToClear); | 26 | serviceSession.clearStorageData(targetsToClear); |
26 | } else { | 27 | } else { |
27 | debug('Clearing all targets'); | 28 | console.log('Clearing all targets'); |
28 | serviceSession.clearStorageData(); | 29 | serviceSession.clearStorageData(); |
29 | } | 30 | } |
30 | } catch (error) { | 31 | } catch (error) { |
31 | debug(error); | 32 | console.log(error); |
32 | } | 33 | } |
33 | }); | 34 | }); |
34 | 35 | ||