mirror of
https://github.com/onionshare/onionshare.git
synced 2025-01-22 20:51:27 -05:00
Set self.torr_settings_tab to None _before_ deleting the tab
This commit is contained in:
parent
bde94d37fc
commit
de3c95cc50
@ -311,13 +311,13 @@ class TabWidget(QtWidgets.QTabWidget):
|
||||
):
|
||||
self.common.log("TabWidget", "closing a settings tab")
|
||||
|
||||
if type(self.tabs[tab_id]) is TorSettingsTab:
|
||||
self.tor_settings_tab = None
|
||||
|
||||
# Remove the tab
|
||||
self.removeTab(index)
|
||||
del self.tabs[tab.tab_id]
|
||||
|
||||
if type(self.tabs[tab_id]) is TorSettingsTab:
|
||||
self.tor_settings_tab = None
|
||||
|
||||
# If the last tab is closed, open a new one
|
||||
if self.count() == 0:
|
||||
self.new_tab_clicked()
|
||||
|
Loading…
Reference in New Issue
Block a user