소스 검색

better eq check

Raanan Weber 5 년 전
부모
커밋
5ec117e974
2개의 변경된 파일2개의 추가작업 그리고 2개의 파일을 삭제
  1. 1 1
      src/Cameras/Inputs/arcRotateCameraVRDeviceOrientationInput.ts
  2. 1 1
      src/Cameras/Inputs/freeCameraDeviceOrientationInput.ts

+ 1 - 1
src/Cameras/Inputs/arcRotateCameraVRDeviceOrientationInput.ts

@@ -72,7 +72,7 @@ export class ArcRotateCameraVRDeviceOrientationInput implements ICameraInput<Arc
             if (typeof (<any>DeviceOrientationEvent).requestPermission === 'function') {
                 (<any>DeviceOrientationEvent).requestPermission()
                     .then((response: string) => {
-                        if (response == 'granted') {
+                        if (response === 'granted') {
                             hostWindow!.addEventListener("deviceorientation", this._deviceOrientationHandler);
                         } else {
                             Tools.Warn("Permission not granted.");

+ 1 - 1
src/Cameras/Inputs/freeCameraDeviceOrientationInput.ts

@@ -146,7 +146,7 @@ export class FreeCameraDeviceOrientationInput implements ICameraInput<FreeCamera
             if (typeof (<any>DeviceOrientationEvent).requestPermission === 'function') {
                 (<any>DeviceOrientationEvent).requestPermission()
                     .then((response: string) => {
-                        if (response == 'granted') {
+                        if (response === 'granted') {
                             eventHandler();
                         } else {
                             Tools.Warn("Permission not granted.");