From c031636bf6702b89b29a695de13068a19832da8a Mon Sep 17 00:00:00 2001 From: danbulant Date: Sun, 23 Jun 2019 15:06:37 +0200 Subject: [PATCH] fix path in electron --- html/node.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/html/node.js b/html/node.js index 7f5e47d..54bdfb9 100644 --- a/html/node.js +++ b/html/node.js @@ -28,7 +28,7 @@ if(typeof module !== undefined){ refreshFiles(); }) var loc = window.location.pathname; - var dir = loc.substring(0, loc.lastIndexOf('/')); + var dir = loc.substring(1, loc.lastIndexOf('/'));//fix file:///, only on node ipcRenderer.send('listFiles', dir); } else { //no NODE integration, propably browser access