Skip to content

Commit

Permalink
Stricter checking for operator
Browse files Browse the repository at this point in the history
  • Loading branch information
aravindet committed Jun 20, 2016
1 parent 4c28b2e commit 7505616
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "jsonop",
"version": "3.0.2",
"version": "3.0.3",
"description": "JSON-encoded operations on JSON documents",
"main": "src/index",
"scripts": {
Expand Down
2 changes: 1 addition & 1 deletion src/jsonop.js
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ module.exports = function (left, right, doMerge) {
};

function isOperator(value) {
return (typeof value === "string" && value[0] === "$");
return (typeof value === "string" && value in opfn);
}

function isOperation(value) {
Expand Down

0 comments on commit 7505616

Please sign in to comment.