mirror of
https://github.com/DeNNiiInc/dbgate.git
synced 2026-04-20 19:26:00 +00:00
fix
This commit is contained in:
@@ -1,7 +1,7 @@
|
|||||||
import _ from 'lodash';
|
import _ from 'lodash';
|
||||||
import { currentDatabase, getCurrentDatabase, getLockedDatabaseMode, openedTabs } from '../stores';
|
import { currentDatabase, getCurrentDatabase, getLockedDatabaseMode, openedTabs } from '../stores';
|
||||||
import { shouldShowTab } from '../widgets/TabsPanel.svelte';
|
import { shouldShowTab } from '../widgets/TabsPanel.svelte';
|
||||||
import { callWhenAppLoaded } from './appLoadManager';
|
import { callWhenAppLoaded, getAppLoaded } from './appLoadManager';
|
||||||
import { getConnectionInfo } from './metadataLoaders';
|
import { getConnectionInfo } from './metadataLoaders';
|
||||||
|
|
||||||
let lastCurrentTab = null;
|
let lastCurrentTab = null;
|
||||||
@@ -32,6 +32,7 @@ openedTabs.subscribe(value => {
|
|||||||
|
|
||||||
currentDatabase.subscribe(currentDb => {
|
currentDatabase.subscribe(currentDb => {
|
||||||
if (!getLockedDatabaseMode()) return;
|
if (!getLockedDatabaseMode()) return;
|
||||||
|
if (!currentDb && !getAppLoaded()) return;
|
||||||
openedTabs.update(tabs => {
|
openedTabs.update(tabs => {
|
||||||
const newTabs = tabs.map(tab => ({
|
const newTabs = tabs.map(tab => ({
|
||||||
...tab,
|
...tab,
|
||||||
|
|||||||
Reference in New Issue
Block a user