diff --git a/index.js b/index.js index a25b82e8..c01c388f 100644 --- a/index.js +++ b/index.js @@ -2764,7 +2764,7 @@ def('parseJson', {}, [TypeRep, $.String, $Maybe(a)], - function(type, json) { return filter(is(type), encase(JSON.parse, json)); }); + function(type, s) { return filter(is(type), encase(JSON.parse, s)); }); //. ### RegExp diff --git a/test/index.js b/test/index.js index 570f01ee..166fcf5a 100644 --- a/test/index.js +++ b/test/index.js @@ -4149,8 +4149,8 @@ describe('parse', function() { eq(S.parseJson(Object, '[Invalid JSON]'), S.Nothing()); }); - it('returns a Nothing when the parsed result is not a member of the given Type', function() { - eq(S.parseJson(Array, '{"foo": "bar"}'), S.Nothing()); + it('returns a Nothing when the parsed result is not a member of the given type', function() { + eq(S.parseJson(Array, '{"foo":"bar"}'), S.Nothing()); }); });