Skip to content

Commit

Permalink
fix: _getInstance and selectedInstance old logic
Browse files Browse the repository at this point in the history
Doesn't seem to have worked since we moved the incomplete
template into the component.
  • Loading branch information
Patrik Kullman authored and cristinecula committed Apr 15, 2020
1 parent 13a284a commit c2908eb
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions cosmoz-data-nav.js
Original file line number Diff line number Diff line change
Expand Up @@ -757,11 +757,11 @@ class CosmozDataNav extends translatable(mixinBehaviors([IronResizableBehavior],
}

_getInstance(selectedElement) {
if (selectedElement == null || selectedElement.children.length < 2) {
if (selectedElement == null) {
return;
}
// index 0 is incomplete element
return selectedElement.children[1];
return selectedElement.children[0];
}

_getItem(index, items = this.items) {
Expand Down

0 comments on commit c2908eb

Please sign in to comment.