Skip to content
This repository has been archived by the owner on Dec 11, 2019. It is now read-only.

Commit

Permalink
Merge pull request #8227 from brave/closeTabFix
Browse files Browse the repository at this point in the history
Only close frame if not already closed on tab
  • Loading branch information
bsclifton authored Apr 11, 2017
2 parents 6293496 + c2e03af commit 3a515d3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion js/components/tab.js
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@ class Tab extends ImmutableComponent {

onTabClosedWithMouse (event) {
event.stopPropagation()
if (this.props.onTabClosedWithMouse) {
if (this.props.onTabClosedWithMouse && this.frame && !this.frame.isEmpty()) {
this.props.onTabClosedWithMouse(this.tabNode.parentNode.getBoundingClientRect())
windowActions.closeFrame(windowStore.getFrames(), this.frame)
}
Expand Down

0 comments on commit 3a515d3

Please sign in to comment.