Needle Engine

Changes between version 3.41.1-alpha and 3.41.1-alpha.1
Files changed (1) hide show
  1. src/engine/xr/NeedleXRSession.ts +5 -5
src/engine/xr/NeedleXRSession.ts CHANGED
@@ -389,11 +389,6 @@
389
389
 
390
390
  // setup session init args, make sure we have default values
391
391
  if (!init) init = {};
392
-
393
- // Fix: define these here because VariantLauncher crashes otherwise. Spec: https://immersive-web.github.io/webxr/#feature-dependencies
394
- // Issue: https://linear.app/needle/issue/NE-5136
395
- init.optionalFeatures ??= [];
396
- init.requiredFeatures ??= [];
397
392
 
398
393
  switch (mode) {
399
394
 
@@ -439,6 +434,11 @@
439
434
  break;
440
435
  }
441
436
 
437
+ // Fix: define these here because VariantLauncher crashes otherwise. Spec: https://immersive-web.github.io/webxr/#feature-dependencies
438
+ // Issue: https://linear.app/needle/issue/NE-5136
439
+ init.optionalFeatures ??= [];
440
+ init.requiredFeatures ??= [];
441
+
442
442
  // we stop a temporary session here (if any runs)
443
443
  await TemporaryXRContext.stop();