diff options
author | Alphrag <34252790+Alphrag@users.noreply.github.com> | 2023-04-28 00:38:30 +0100 |
---|---|---|
committer | Vijay Aravamudhan <vraravam@users.noreply.github.com> | 2023-04-28 06:24:01 +0530 |
commit | b4724e034e2e3f88e6625ead891162cc8a776367 (patch) | |
tree | afd57bcb37430481eb63fd33d74e226a1c05658a /src/models/Service.ts | |
parent | 6.2.7-nightly.8 [skip ci] (diff) | |
download | ferdium-app-b4724e034e2e3f88e6625ead891162cc8a776367.tar.gz ferdium-app-b4724e034e2e3f88e6625ead891162cc8a776367.tar.zst ferdium-app-b4724e034e2e3f88e6625ead891162cc8a776367.zip |
Update electron
Diffstat (limited to 'src/models/Service.ts')
-rw-r--r-- | src/models/Service.ts | 42 |
1 files changed, 22 insertions, 20 deletions
diff --git a/src/models/Service.ts b/src/models/Service.ts index 493620ba4..0cbfa60e2 100644 --- a/src/models/Service.ts +++ b/src/models/Service.ts | |||
@@ -527,27 +527,29 @@ export default class Service { | |||
527 | this._didMediaPaused(); | 527 | this._didMediaPaused(); |
528 | }); | 528 | }); |
529 | 529 | ||
530 | webviewWebContents.on('login', (event, _, authInfo, callback) => { | 530 | if (webviewWebContents) { |
531 | // const authCallback = callback; | 531 | webviewWebContents.on('login', (event, _, authInfo, callback) => { |
532 | debug('browser login event', authInfo); | 532 | // const authCallback = callback; |
533 | event.preventDefault(); | 533 | debug('browser login event', authInfo); |
534 | 534 | event.preventDefault(); | |
535 | if (authInfo.isProxy && authInfo.scheme === 'basic') { | 535 | |
536 | debug('Sending service echo ping'); | 536 | if (authInfo.isProxy && authInfo.scheme === 'basic') { |
537 | webviewWebContents.send('get-service-id'); | 537 | debug('Sending service echo ping'); |
538 | 538 | webviewWebContents.send('get-service-id'); | |
539 | debug('Received service id', this.id); | 539 | |
540 | 540 | debug('Received service id', this.id); | |
541 | const ps = stores.settings.proxy[this.id]; | 541 | |
542 | 542 | const ps = stores.settings.proxy[this.id]; | |
543 | if (ps) { | 543 | |
544 | debug('Sending proxy auth callback for service', this.id); | 544 | if (ps) { |
545 | callback(ps.user, ps.password); | 545 | debug('Sending proxy auth callback for service', this.id); |
546 | } else { | 546 | callback(ps.user, ps.password); |
547 | debug('No proxy auth config found for', this.id); | 547 | } else { |
548 | debug('No proxy auth config found for', this.id); | ||
549 | } | ||
548 | } | 550 | } |
549 | } | 551 | }); |
550 | }); | 552 | } |
551 | } | 553 | } |
552 | 554 | ||
553 | initializeWebViewListener(): void { | 555 | initializeWebViewListener(): void { |