Skip to content

Commit

Permalink
Use null-prototype objects
Browse files Browse the repository at this point in the history
  • Loading branch information
taion committed Apr 29, 2016
1 parent 658f1e5 commit 94eb5a5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ function parseLiteral(ast) {
case Kind.FLOAT:
return parseFloat(ast.value);
case Kind.OBJECT: {
const value = {};
const value = Object.create(null);
ast.fields.forEach(field => {
value[field.name.value] = parseLiteral(field.value);
});
Expand Down

0 comments on commit 94eb5a5

Please sign in to comment.