Serve helpers up while running in debug mode
authorDarren <darren@darrenwhitlen.com>
Thu, 18 Dec 2014 22:56:19 +0000 (22:56 +0000)
committerDarren <darren@darrenwhitlen.com>
Thu, 18 Dec 2014 22:56:19 +0000 (22:56 +0000)
server/settingsgenerator.js

index 083a3788f14e9b48c5cb5e835057ce0590cdd071..1fe8c480d26db40856f70eef7dce62a8115e9e4f 100644 (file)
@@ -249,4 +249,12 @@ function addScripts(vars, debug) {
             'src/applets/startup.js'
         ]
     ]);
+
+    var helpers_path = global.config.public_http + 'src/helpers/';
+    var helpers_sources = fs.readdirSync(helpers_path)
+        .map(function(file){
+            return 'src/helpers/' + file;
+        });
+
+    vars.scripts = vars.scripts.concat(helpers_sources);
 }