diff options
Diffstat (limited to 'src/index.ts')
-rw-r--r-- | src/index.ts | 19 |
1 files changed, 2 insertions, 17 deletions
diff --git a/src/index.ts b/src/index.ts index 8419d5cf9..fe254b4f6 100644 --- a/src/index.ts +++ b/src/index.ts | |||
@@ -50,7 +50,7 @@ import { openExternalUrl } from './helpers/url-helpers'; | |||
50 | import userAgent from './helpers/userAgent-helpers'; | 50 | import userAgent from './helpers/userAgent-helpers'; |
51 | import { translateTo } from './helpers/translation-helpers'; | 51 | import { translateTo } from './helpers/translation-helpers'; |
52 | import { darkThemeGrayDarkest } from './themes/legacy'; | 52 | import { darkThemeGrayDarkest } from './themes/legacy'; |
53 | import { readCerts, removeNewLines } from './helpers/certs-helpers'; | 53 | import { checkIfCertIsPresent } from './helpers/certs-helpers'; |
54 | 54 | ||
55 | const debug = require('./preload-safe-debug')('Ferdium:App'); | 55 | const debug = require('./preload-safe-debug')('Ferdium:App'); |
56 | 56 | ||
@@ -773,21 +773,6 @@ app.on( | |||
773 | return; | 773 | return; |
774 | } | 774 | } |
775 | 775 | ||
776 | const trustedCerts = readCerts(); | 776 | callback(checkIfCertIsPresent(certificate.data)); |
777 | if (!trustedCerts) { | ||
778 | callback(false); | ||
779 | return; | ||
780 | } | ||
781 | |||
782 | const isTrustedCert = trustedCerts.includes( | ||
783 | removeNewLines(certificate.data), | ||
784 | ); | ||
785 | |||
786 | if (isTrustedCert) { | ||
787 | callback(true); | ||
788 | return; | ||
789 | } | ||
790 | |||
791 | callback(false); | ||
792 | }, | 777 | }, |
793 | ); | 778 | ); |