client-app/app/lib/preload.js in logster-2.1.2 vs client-app/app/lib/preload.js in logster-2.2.0
- old
+ new
@@ -1,20 +1,20 @@
-let CONTAINER;
-let isInitialized = false;
-
-// exported so that it can be used in tests
-export function init() {
- const dataset = document.getElementById("preloaded-data").dataset;
- CONTAINER = Em.$.extend(JSON.parse(dataset.preloaded), {
- rootPath: dataset.rootPath
- });
- isInitialized = true;
-}
-
-export default {
- get(key) {
- if (!isInitialized) {
- init();
- }
- return Em.get(CONTAINER, key);
- }
-};
+let CONTAINER;
+let isInitialized = false;
+
+// exported so that it can be used in tests
+export function init() {
+ const dataset = document.getElementById("preloaded-data").dataset;
+ CONTAINER = Em.$.extend(JSON.parse(dataset.preloaded), {
+ rootPath: dataset.rootPath
+ });
+ isInitialized = true;
+}
+
+export default {
+ get(key) {
+ if (!isInitialized) {
+ init();
+ }
+ return Em.get(CONTAINER, key);
+ }
+};