From b9ceea03ca066e6233b92983aa3dd45c83e89a73 Mon Sep 17 00:00:00 2001 From: workingjubilee Date: Sun, 18 Aug 2019 15:55:54 -0700 Subject: [PATCH] Solves easy lints --- src/javascript/tests/core/erlang_compat/maps_spec.js | 4 +--- src/javascript/tests/with.spec.js | 4 ++-- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/src/javascript/tests/core/erlang_compat/maps_spec.js b/src/javascript/tests/core/erlang_compat/maps_spec.js index 1a504227..31a20dcd 100644 --- a/src/javascript/tests/core/erlang_compat/maps_spec.js +++ b/src/javascript/tests/core/erlang_compat/maps_spec.js @@ -67,9 +67,7 @@ test('put/3', (t) => { test('take/2', (t) => { const myMap = new Map([['a', 1], ['b', 2]]); - let a; - let result; - [a, result] = Core.maps.take('a', myMap); + const [a, result] = Core.maps.take('a', myMap); t.is(a, 1); t.is(result.has('a'), false); }); diff --git a/src/javascript/tests/with.spec.js b/src/javascript/tests/with.spec.js index 0ac09ced..31fb2c49 100644 --- a/src/javascript/tests/with.spec.js +++ b/src/javascript/tests/with.spec.js @@ -1,5 +1,5 @@ -import Core from '../lib/core'; import test from 'ava'; +import Core from '../lib/core'; const Patterns = Core.Patterns; const SpecialForms = Core.SpecialForms; @@ -31,7 +31,7 @@ test('with', (t) => { const value = SpecialForms._with( [new Tuple(Symbol.for('ok'), $), () => map_fetch(opts, 'width')], - [new Tuple(Symbol.for('ok'), $), width => map_fetch(opts, 'height')], + [new Tuple(Symbol.for('ok'), $), () => map_fetch(opts, 'height')], (width, height) => new Tuple(Symbol.for('ok'), width * height), );