Skip to content

Commit 40402d8

Browse files
andrew-colemanmattbaileyuk
authored andcommitted
remove extraneous code
1 parent 7f3adf6 commit 40402d8

File tree

1 file changed

+4
-5
lines changed

1 file changed

+4
-5
lines changed

jsonata.js

+4-5
Original file line numberDiff line numberDiff line change
@@ -1387,9 +1387,8 @@ var jsonata = (function() {
13871387
function isNumeric(n) {
13881388
var isNum = false;
13891389
if(typeof n === 'number') {
1390-
var num = parseFloat(n);
1391-
isNum = !isNaN(num);
1392-
if (isNum && !isFinite(num)) {
1390+
isNum = !isNaN(n);
1391+
if (isNum && !isFinite(n)) {
13931392
throw {
13941393
code: "D1001",
13951394
value: n,
@@ -2607,9 +2606,9 @@ var jsonata = (function() {
26072606
if(isFunction(lhs)) {
26082607
// this is function chaining (func1 ~> func2)
26092608
// λ($f, $g) { λ($x){ $g($f($x)) } }
2610-
result = yield * apply(chain, [lhs, func], environment, null);
2609+
result = yield * apply(chain, [lhs, func], environment);
26112610
} else {
2612-
result = yield * apply(func, [lhs], environment, null);
2611+
result = yield * apply(func, [lhs], environment);
26132612
}
26142613

26152614
}

0 commit comments

Comments
 (0)