Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit d22a410

Browse files
kuychacoBinaryMuse
authored andcommitted
Throw error from DockItem#activate only for non-destroyed dock item
1 parent c211f21 commit d22a410

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

lib/views/dock-item.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -126,8 +126,8 @@ export default class DockItem extends React.Component {
126126
if (dock && dock.show) {
127127
dock.show();
128128
}
129-
} else {
130-
throw new Error('Cannot find pane for item in `DockItem#activate`');
129+
} else if (this.dockItem && !this.didCloseItem) {
130+
throw new Error('Could not find pane for a non-destroyed DockItem');
131131
}
132132
});
133133
}

0 commit comments

Comments
 (0)