File tree Expand file tree Collapse file tree 1 file changed +4
-2
lines changed
superset-frontend/src/middleware Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -81,7 +81,9 @@ const loggerMiddleware = store => next => action => {
81
81
const { eventName } = action . payload ;
82
82
let { eventData = { } } = action . payload ;
83
83
84
- if ( dashboardInfo ?. id && eventData . path ?. includes ( '/dashboard/' ) ) {
84
+ const path = eventData . path || window ?. location ?. href ;
85
+
86
+ if ( dashboardInfo ?. id && path ?. includes ( '/dashboard/' ) ) {
85
87
logMetadata = {
86
88
source : 'dashboard' ,
87
89
source_id : dashboardInfo . id ,
@@ -95,7 +97,7 @@ const loggerMiddleware = store => next => action => {
95
97
...( explore . slice . slice_id && { slice_id : explore . slice . slice_id } ) ,
96
98
...logMetadata ,
97
99
} ;
98
- } else if ( eventData . path ?. includes ( '/sqllab/' ) ) {
100
+ } else if ( path ?. includes ( '/sqllab/' ) ) {
99
101
const editor = sqlLab . queryEditors . find (
100
102
( { id } ) => id === sqlLab . tabHistory . slice ( - 1 ) [ 0 ] ,
101
103
) ;
You can’t perform that action at this time.
0 commit comments