From 00abe6ef083ab2b22d8f9eaadcd9eb418344a5b0 Mon Sep 17 00:00:00 2001 From: Matei Adriel Date: Tue, 22 Jan 2019 21:06:48 +0200 Subject: [PATCH] typescript(translucid): hate it even more (jk) Signed-off-by: prescientmoon --- typescript/translucid/Translucid.js | 4 ++-- typescript/translucid/Translucid.ts | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/typescript/translucid/Translucid.js b/typescript/translucid/Translucid.js index 82b5d86..322148c 100644 --- a/typescript/translucid/Translucid.js +++ b/typescript/translucid/Translucid.js @@ -25,8 +25,8 @@ class Translucid { const object = JSON.parse(json); for (let i in object) { const classes = object[i].classes || []; - this.bind(object[i].path, object[i].file, classes); - console.log(`Binded room with name ${object[i].file} and path ${object[i].filepath} with classes ${classes}`); + this.bind(i, object[i].file, classes); + console.log(`Binded room with name ${i} and path ${object[i].path} with classes ${classes}`); } } bind(path = "/", filepath = "", classes = []) { diff --git a/typescript/translucid/Translucid.ts b/typescript/translucid/Translucid.ts index e658359..95eb0d4 100644 --- a/typescript/translucid/Translucid.ts +++ b/typescript/translucid/Translucid.ts @@ -30,8 +30,8 @@ class Translucid { for (let i in object){ const classes = object[i].classes || []; - this.bind(object[i].path,object[i].file,classes); - console.log(`Binded room with name ${object[i].file} and path ${object[i].filepath} with classes ${classes}`) + this.bind(i,object[i].file,classes); + console.log(`Binded room with name ${i} and path ${object[i].path} with classes ${classes}`) } } bind(path:string = "/", filepath:string = "", classes:Array = []):void{