Closed ashaffer closed 10 years ago
Is there an update on this? This happens in node.js (v0.11.3) as well:
> qs.parse('user[name][first]=Tobi&user[email]=tobi@learnboost.com');
{ user:
{ name: { first: 'Tobi', [__proto__]: {} },
email: 'tobi@learnboost.com',
[__proto__]: {} },
[__proto__]: {} }
(example from README)
@visionmedia Just noticed a fix has already been applied. Would it be possible to release a new version?
Closed by #86.
In the latest version of Chrome they have subtly changed the behavior of proto. It is now defined as an accessor on Object.prototype, which means that when you do an Object.create(null) proto is no longer a special property, which means that querystring.parse returns an object with a property called 'proto' that still has a null prototype chain.
I'm running on chrome Version 28.0.1500.52 beta on Ubuntu. A simple test to see if your version of chrome is effected by this is
v8 bug report on the issue confirming the behavior is expected: https://code.google.com/p/v8/issues/detail?id=2727