diff --git a/src/utils/vr-caps-detect.js b/src/utils/vr-caps-detect.js index 297842342e7937922aa2286ebbae0cd2a53cb2a4..224f1bb49ba60a0627808a73dc6c3139d7df8aac 100644 --- a/src/utils/vr-caps-detect.js +++ b/src/utils/vr-caps-detect.js @@ -67,11 +67,10 @@ export async function getAvailableVREntryTypes() { // Browser for now since Samsung Internet requires an additional WebVR installation + flag, so return "maybe". // // If we are in Oculus Browser (ie, we are literally wearing a GearVR) then return 'yes'. - const gearvr = isMaybeGearVRCompatibleDevice() - ? isOculusBrowser - ? VR_DEVICE_AVAILABILITY.yes - : VR_DEVICE_AVAILABILITY.maybe - : VR_DEVICE_AVAILABILITY.no; + let gearvr = VR_DEVICE_AVAILABILITY.no; + if (isMaybeGearVRCompatibleDevice()) { + gearvr = isOculusBrowser ? VR_DEVICE_AVAILABILITY.yes : VR_DEVICE_AVAILABILITY.maybe; + } // For daydream detection, we first check if they are on an Android compatible device, and assume they // may support daydream *unless* this browser has WebVR capabilities, in which case we can do better.