diff --git a/src/CustomElements.js b/src/CustomElements.js index 0250277..d8bc6b7 100644 --- a/src/CustomElements.js +++ b/src/CustomElements.js @@ -172,11 +172,11 @@ if (useNative) { // prototype for precise mixing in if (!Object.__proto__) { // default prototype - var native = HTMLElement.prototype; + var nativePrototype = HTMLElement.prototype; // work out prototype when using type-extension if (definition.is) { var inst = document.createElement(definition.tag); - native = Object.getPrototypeOf(inst); + nativePrototype = Object.getPrototypeOf(inst); } // ensure __proto__ reference is installed at each point on the prototype // chain. @@ -184,14 +184,14 @@ if (useNative) { // of prototype swizzling. In this case, this generated __proto__ provides // limited support for prototype traversal. var proto = definition.prototype, ancestor; - while (proto && (proto !== native)) { + while (proto && (proto !== nativePrototype)) { var ancestor = Object.getPrototypeOf(proto); proto.__proto__ = ancestor; proto = ancestor; } } // cache this in case of mixin - definition.native = native; + definition.native = nativePrototype; } // SECTION 4