This is an automated email from the ASF dual-hosted git repository.

michaelsmolina pushed a commit to branch 5.0-extensions
in repository https://gitbox.apache.org/repos/asf/superset.git


The following commit(s) were added to refs/heads/5.0-extensions by this push:
     new 5c43b13c1e fix: Change database event in core (#35071)
5c43b13c1e is described below

commit 5c43b13c1e5134d1437d4eaccfcad3967890899b
Author: Michael S. Molina <70410625+michael-s-mol...@users.noreply.github.com>
AuthorDate: Tue Sep 9 11:50:49 2025 -0300

    fix: Change database event in core (#35071)
    
    (cherry picked from commit 4c2b27e7f09513d09306d2297791387cbb88275b)
---
 superset-frontend/src/core/sqlLab.ts | 7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)

diff --git a/superset-frontend/src/core/sqlLab.ts 
b/superset-frontend/src/core/sqlLab.ts
index 8f374dea1b..719d984fc4 100644
--- a/superset-frontend/src/core/sqlLab.ts
+++ b/superset-frontend/src/core/sqlLab.ts
@@ -102,8 +102,11 @@ export const onDidChangeEditorDatabase: typeof 
sqlLabType.onDidChangeEditorDatab
     createActionListener(
       predicate(QUERY_EDITOR_SETDB),
       listener,
-      (action: { type: string; queryEditor: { dbId: number } }) =>
-        action.queryEditor.dbId,
+      (action: {
+        type: string;
+        dbId?: number;
+        queryEditor: { dbId: number };
+      }) => action.dbId || action.queryEditor.dbId,
       thisArgs,
     );
 

Reply via email to