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

Commit

Permalink
check to see if the tab was active before it was closed
Browse files Browse the repository at this point in the history
fix #9306
  • Loading branch information
bridiver authored and cezaraugusto committed Jun 20, 2017
1 parent e6bf220 commit f016822
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions app/browser/reducers/tabsReducer.js
Original file line number Diff line number Diff line change
Expand Up @@ -37,12 +37,13 @@ const updateActiveTab = (state, closeTabId) => {
return
}

if (!tabState.isActive(state, closeTabId)) {
const windowId = tabState.getWindowId(state, closeTabId)
if (windowId === windowState.WINDOW_ID_NONE) {
return
}

const windowId = tabState.getWindowId(state, closeTabId)
if (windowId === windowState.WINDOW_ID_NONE) {
const lastActiveTabId = tabState.getTabsByLastActivated(state, windowId).last()
if (lastActiveTabId !== closeTabId && !tabState.isActive(state, closeTabId)) {
return
}

Expand Down

0 comments on commit f016822

Please sign in to comment.