Allow injection of additional undefined fields through object literal constructors and #set().

This commit is contained in:
Jürg Lehni 2014-11-18 15:24:40 -08:00
parent d5471c480f
commit 912f7ad629

View file

@ -68,8 +68,7 @@ Base.inject(/** @lends Base# */{
// inheritance trick in the argument reading code.
var orig = props._filtering || props;
for (var key in orig) {
if (key in this && orig.hasOwnProperty(key)
&& !(exclude && exclude[key])) {
if (orig.hasOwnProperty(key) && !(exclude && exclude[key])) {
var value = props[key];
// Due to the _filtered inheritance trick, undefined is used
// to mask already consumed named arguments.