File tree Expand file tree Collapse file tree 1 file changed +12
-5
lines changed
Expand file tree Collapse file tree 1 file changed +12
-5
lines changed Original file line number Diff line number Diff line change 9393 if ( ! constructor . hasOwnProperty ( JSCompiler_renameProperty ( '__ownProperties' , constructor ) ) ) {
9494 let props = null ;
9595
96- if ( constructor . hasOwnProperty ( JSCompiler_renameProperty ( 'properties' , constructor ) ) && constructor . properties ) {
97- props = normalizeProperties ( constructor . properties ) ;
96+ if ( constructor . hasOwnProperty ( JSCompiler_renameProperty ( 'properties' , constructor ) ) ) {
97+ const properties = constructor . properties ;
98+
99+ if ( properties ) {
100+ props = normalizeProperties ( properties ) ;
101+ }
98102 }
99103
100104 constructor . __ownProperties = props ;
117121 * @suppress {missingProperties} Interfaces in closure do not inherit statics, but classes do
118122 */
119123 static get observedAttributes ( ) {
120- Polymer . telemetry . register ( this . prototype ) ;
121- const props = this . _properties ;
122- return props ? Object . keys ( props ) . map ( p => this . attributeNameForProperty ( p ) ) : [ ] ;
124+ if ( ! this . hasOwnProperty ( '__observedAttributes' ) ) {
125+ Polymer . telemetry . register ( this . prototype ) ;
126+ const props = this . _properties ;
127+ this . __observedAttributes = props ? Object . keys ( props ) . map ( p => this . attributeNameForProperty ( p ) ) : [ ] ;
128+ }
129+ return this . __observedAttributes ;
123130 }
124131
125132 /**
You can’t perform that action at this time.
0 commit comments