Skip to content

Commit

Permalink
Wrap other hasOwnProperty checks in JSCompiler_renameProperty.
Browse files Browse the repository at this point in the history
  • Loading branch information
bicknellr committed Aug 26, 2019
1 parent 9e90fd2 commit 0541b21
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions lib/mixins/properties-changed.js
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ export const PropertiesChanged = dedupingMixin(
*/
_createPropertyAccessor(property, readOnly) {
this._addPropertyToAttributeMap(property);
if (!this.hasOwnProperty('__dataHasAccessor')) {
if (!this.hasOwnProperty(JSCompiler_renameProperty('__dataHasAccessor', this))) {
this.__dataHasAccessor = Object.assign({}, this.__dataHasAccessor);
}
if (!this.__dataHasAccessor[property]) {
Expand All @@ -131,7 +131,7 @@ export const PropertiesChanged = dedupingMixin(
* @override
*/
_addPropertyToAttributeMap(property) {
if (!this.hasOwnProperty('__dataAttributes')) {
if (!this.hasOwnProperty(JSCompiler_renameProperty('__dataAttributes', this))) {
this.__dataAttributes = Object.assign({}, this.__dataAttributes);
}
if (!this.__dataAttributes[property]) {
Expand Down
2 changes: 1 addition & 1 deletion lib/mixins/properties-mixin.js
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ export const PropertiesMixin = dedupingMixin(superClass => {
* @nocollapse
*/
static get observedAttributes() {
if (!this.hasOwnProperty('__observedAttributes')) {
if (!this.hasOwnProperty(JSCompiler_renameProperty('__observedAttributes', this))) {
register(this.prototype);
const props = this._properties;
this.__observedAttributes = props ? Object.keys(props).map(p => this.attributeNameForProperty(p)) : [];
Expand Down

0 comments on commit 0541b21

Please sign in to comment.