Page MenuHomePhabricator

mw.Map should not get confused by keys that look like Object.prototype
Closed, ResolvedPublic

Description

var a = new mw.Map();

a.get('constructor');
// function Object() { [native code] }

a.set('hasOwnProperty');

// Let the party begin.

It's almost as fun as setting
var true = !1;
var false = !0;

.. in languages that support that, fortunately javascript isn't one of them.


Version: 1.17.x
Severity: normal

Details

Reference
bz45331

Event Timeline

bzimport raised the priority of this task from to Normal.Nov 22 2014, 1:20 AM
bzimport set Reference to bz45331.
Krinkle created this task.Feb 24 2013, 2:21 PM

Change-Id: I035e23f700e2120618ed4fbe5ce95c7f9b947e41