|
204 | 204 | }, |
205 | 205 |
|
206 | 206 | detached: function() { |
207 | | - if (this._instances) { |
208 | | - for (var i=0; i<this._instances.length; i++) { |
209 | | - this._detachRow(i); |
210 | | - } |
| 207 | + for (var i=0; i<this._instances.length; i++) { |
| 208 | + this._detachRow(i); |
211 | 209 | } |
212 | 210 | }, |
213 | 211 |
|
214 | 212 | attached: function() { |
215 | | - if (this._instances) { |
216 | | - var parentNode = Polymer.dom(this).parentNode; |
217 | | - for (var i=0; i<this._instances.length; i++) { |
218 | | - Polymer.dom(parentNode).insertBefore(this._instances[i].root, this); |
219 | | - } |
| 213 | + var parentNode = Polymer.dom(this).parentNode; |
| 214 | + for (var i=0; i<this._instances.length; i++) { |
| 215 | + Polymer.dom(parentNode).insertBefore(this._instances[i].root, this); |
220 | 216 | } |
221 | 217 | }, |
222 | 218 |
|
|
567 | 563 |
|
568 | 564 | // Implements extension point from Templatizer mixin |
569 | 565 | _showHideChildren: function(hidden) { |
570 | | - if (this._instances) { |
571 | | - for (var i=0; i<this._instances.length; i++) { |
572 | | - this._instances[i]._showHideChildren(hidden); |
573 | | - } |
| 566 | + for (var i=0; i<this._instances.length; i++) { |
| 567 | + this._instances[i]._showHideChildren(hidden); |
574 | 568 | } |
575 | 569 | }, |
576 | 570 |
|
|
607 | 601 | // Called as side-effect of a host property change, responsible for |
608 | 602 | // notifying parent path change on each inst |
609 | 603 | _forwardParentProp: function(prop, value) { |
610 | | - if (this._instances) { |
611 | | - this._instances.forEach(function(inst) { |
612 | | - inst.__setProperty(prop, value, true); |
613 | | - }, this); |
614 | | - } |
| 604 | + this._instances.forEach(function(inst) { |
| 605 | + inst.__setProperty(prop, value, true); |
| 606 | + }, this); |
615 | 607 | }, |
616 | 608 |
|
617 | 609 | // Implements extension point from Templatizer |
618 | 610 | // Called as side-effect of a host path change, responsible for |
619 | 611 | // notifying parent path change on each inst |
620 | 612 | _forwardParentPath: function(path, value) { |
621 | | - if (this._instances) { |
622 | | - this._instances.forEach(function(inst) { |
623 | | - inst.notifyPath(path, value, true); |
624 | | - }, this); |
625 | | - } |
| 613 | + this._instances.forEach(function(inst) { |
| 614 | + inst.notifyPath(path, value, true); |
| 615 | + }, this); |
626 | 616 | }, |
627 | 617 |
|
628 | 618 | // Called as a side effect of a host items.<key>.<path> path change, |
|
0 commit comments