From 2fadcb8d041983c0f5b13d77f45236ebdbcdfa63 Mon Sep 17 00:00:00 2001 From: Kyle Spearrin Date: Fri, 14 Sep 2018 08:07:55 -0400 Subject: [PATCH] is safari check --- src/services/webCryptoFunction.service.ts | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/services/webCryptoFunction.service.ts b/src/services/webCryptoFunction.service.ts index a7fc99638ed..fc37e3ae3ec 100644 --- a/src/services/webCryptoFunction.service.ts +++ b/src/services/webCryptoFunction.service.ts @@ -8,8 +8,6 @@ import { Utils } from '../misc/utils'; import { DecryptParameters } from '../models/domain/decryptParameters'; import { SymmetricCryptoKey } from '../models/domain/symmetricCryptoKey'; -import { DeviceType } from '../enums/deviceType'; - export class WebCryptoFunctionService implements CryptoFunctionService { private crypto: Crypto; private subtle: SubtleCrypto; @@ -23,7 +21,7 @@ export class WebCryptoFunctionService implements CryptoFunctionService { this.isEdge = platformUtilsService.isEdge(); this.isIE = platformUtilsService.isIE(); const ua = win.navigator.userAgent; - this.isOldSafari = platformUtilsService.getDevice() === DeviceType.SafariBrowser && + this.isOldSafari = platformUtilsService.isSafari() && (ua.indexOf(' Version/10.') > -1 || ua.indexOf(' Version/9.') > -1); }