Success! Looks like we've fixed this one. According to our records the fix was applied for EXTJS-9239 in 4.2.1.744.
  1. #1
    Sencha User
    Join Date
    Sep 2009
    Posts
    3
    Vote Rating
    0
    uchida_t is on a distinguished road

      0  

    Default Ext.util.HashMap should use Object#hasOwnProperty

    Ext.util.HashMap should use Object#hasOwnProperty


    Ext.util.HashMap use native JS Object (this.map).
    But native JS Object has some properties from the beginning.

    var map = new Ext.util.HashMap();
    console.log(map.containsKey('toString')); // true
    console.log(map.containsKey('__proto__')); // true
    console.log(map.get('toString')); // function toString() { [native code] }
    console.log(map.get('__proto__')); // [object Object]


    Ext.util.HashMap should use Object#hasOwnProperty.

    Object.prototype.hasOwnProperty.call(this.map, key)

    http://www.2ality.com/2012/11/proto-breaks-webapps.html
    http://www.2ality.com/2012/01/objects-as-maps.html

  2. #2
    Sencha - Senior Forum Manager mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    Gainesville, FL
    Posts
    37,217
    Vote Rating
    859
    mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute

      0  

    Default


    Thanks for the report! I have opened a bug in our bug tracker.

Thread Participants: 1