From 90e613f33f7a42cc17289a25993de927f198a97b Mon Sep 17 00:00:00 2001 From: bordun Date: Wed, 25 Mar 2020 10:47:37 +0100 Subject: [PATCH] lint: var/let --- src/client/widgets/scripts/script.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/client/widgets/scripts/script.js b/src/client/widgets/scripts/script.js index b5c543bd..1b067706 100644 --- a/src/client/widgets/scripts/script.js +++ b/src/client/widgets/scripts/script.js @@ -71,7 +71,7 @@ class Script extends Widget { value: 0 }) } catch(err) { - var stackline = err.stack ? (err.stack.match(/>:([0-9]+):[0-9]+/) || '') : '', + let stackline = err.stack ? (err.stack.match(/>:([0-9]+):[0-9]+/) || '') : '', line = stackline.length > 1 ? ' at line ' + (parseInt(stackline[1]) - 2) : '' console.log((this.getProp('id') || this.props.id) + '.script error:\n' + err + line) this.script = ()=>{} @@ -98,7 +98,7 @@ class Script extends Widget { meta: false, }) } catch(err) { - var stackline = err.stack ? (err.stack.match(/>:([0-9]+):[0-9]+/) || '') : '', + let stackline = err.stack ? (err.stack.match(/>:([0-9]+):[0-9]+/) || '') : '', line = stackline.length > 1 ? ' at line ' + (parseInt(stackline[1]) - 2) : '' console.log((this.getProp('id') || this.props.id) + '.script error:\n' + err + line) this.script = ()=>{}