From 0af960f3d2180da09627e84d64ac70597584da3c Mon Sep 17 00:00:00 2001
From: Greg Fodor <gfodor@gmail.com>
Date: Tue, 22 May 2018 22:07:51 -0700
Subject: [PATCH] Copy hack into hub.js

---
 src/hub.js | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/src/hub.js b/src/hub.js
index 6153285d1..2b88247d0 100644
--- a/src/hub.js
+++ b/src/hub.js
@@ -6,6 +6,12 @@ import { patchWebGLRenderingContext } from "./utils/webgl";
 patchWebGLRenderingContext();
 
 import "aframe-xr";
+
+// HACK: this has to run after A-Frame but before our bundle, since A-Frame blows away the local storage setting
+if (/[&?]debug=true/.test(window.location.search) && typeof localStorage !== "undefined") {
+  localStorage.debug = "naf-janus-adapter:*";
+}
+
 import "./vendor/GLTFLoader";
 import "networked-aframe/src/index";
 import "naf-janus-adapter";
-- 
GitLab