Skip to content

Commit f700e57

Browse files
fixing forEach on null variable (#801)
Co-authored-by: Alfred Rubin <[email protected]>
1 parent 19401a3 commit f700e57

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/dashboard/DashboardThunks.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -557,7 +557,7 @@ export function patchDashboardVersion(dashboard: any, version: any) {
557557
dashboard.pages.forEach((p) => {
558558
p.reports.forEach((r) => {
559559
if (r.type == 'graph' || r.type == 'map' || r.type == 'graph3d') {
560-
r.settings?.actionsRules.forEach((rule) => {
560+
r.settings?.actionsRules?.forEach((rule) => {
561561
if (
562562
rule?.field &&
563563
(rule?.condition === 'onNodeClick' || rule?.condition == 'Click') &&
@@ -585,7 +585,7 @@ export function upgradeDashboardVersion(dashboard: any, origin: string, target:
585585
r.height *= 2;
586586

587587
if (r.type == 'graph' || r.type == 'map' || r.type == 'graph3d') {
588-
r.settings?.actionsRules.forEach((rule) => {
588+
r.settings?.actionsRules?.forEach((rule) => {
589589
if (
590590
rule?.field &&
591591
(rule?.condition === 'onNodeClick' || rule?.condition == 'Click') &&

0 commit comments

Comments
 (0)