From 282725ab1ec6b92fbf0a47e8d9d94fda6f1ede95 Mon Sep 17 00:00:00 2001 From: DrMaxNix Date: Fri, 9 Sep 2022 13:43:42 +0200 Subject: [PATCH] =?UTF-8?q?=F0=9F=8F=B7=EF=B8=8F=20empty=20variable=20has?= =?UTF-8?q?=20empty=20string=20now?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/parser.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/parser.js b/src/parser.js index 228ed97..c55b324 100644 --- a/src/parser.js +++ b/src/parser.js @@ -211,7 +211,7 @@ class Juicescript_parser { // GET VARIABLE NAME // - if(this.token.value !== null){ + if(this.token.value.length > 0){ // literal variable.name = {type: Juicescript.argument_type.LITERAL, value: this.token.value}; @@ -238,7 +238,7 @@ class Juicescript_parser { } else { // ignore with error - this.error("unable to determine variable name"); + this.error("variable without name"); }