ソースを参照

Remove Utils.platformString()

customisations
alemart 3ヶ月前
コミット
cf6fd1b504
2個のファイルの変更1行の追加14行の削除
  1. 1
    1
      src/core/session.ts
  2. 0
    13
      src/utils/utils.ts

+ 1
- 1
src/core/session.ts ファイルの表示

@@ -203,7 +203,7 @@ export class Session extends AREventTarget<SessionEvent>
203 203
         //alert(Utils.deviceInfo()); // debug
204 204
 
205 205
         // If Safari / iOS, require version 15.2 or later
206
-        if(/(Mac|iOS|iPhone|iPad|iPod)/i.test(Utils.platformString())) {
206
+        if(/(Mac|iOS|iPhone|iPad|iPod)/i.test(navigator.platform)) {
207 207
 
208 208
             /*
209 209
 

+ 0
- 13
src/utils/utils.ts ファイルの表示

@@ -147,19 +147,6 @@ export class Utils
147 147
     }
148 148
 
149 149
     /**
150
-     * Returns a string containing platform brand information
151
-     * @returns platform brand information
152
-     */
153
-    static platformString(): string
154
-    {
155
-        return ((navigator: any): string =>
156
-            typeof navigator.userAgentData === 'object' ? // prefer the NavigatorUAData interface
157
-            navigator.userAgentData.platform : // use only low entropy data
158
-            navigator.platform // navigator.platform is deprecated
159
-        )(navigator);
160
-    }
161
-
162
-    /**
163 150
      * Checks if we're on iOS
164 151
      * @returns true if we're on iOS
165 152
      */

読み込み中…
キャンセル
保存