(electron: typeof Electron)
| 63 | // — nothing else that might share that session. |
| 64 | let directSession: Electron.Session | undefined; |
| 65 | async function getDirectSession(electron: typeof Electron) { |
| 66 | if (!directSession) { |
| 67 | directSession = electron.session.fromPartition('git-sync-direct', { cache: false }); |
| 68 | await directSession.setProxy({ mode: 'direct' }); |
| 69 | } |
| 70 | return directSession; |
| 71 | } |
| 72 | |
| 73 | async function shouldBypassProxy(): Promise<boolean> { |
| 74 | const settings = await services.settings.get(); |