فهرست منبع

fix(dashlist): avoid null ref errors

bergquist 10 سال پیش
والد
کامیت
c6768a93c8
1فایلهای تغییر یافته به همراه2 افزوده شده و 2 حذف شده
  1. 2 2
      public/app/features/dashboard/impression_store.ts

+ 2 - 2
public/app/features/dashboard/impression_store.ts

@@ -31,8 +31,8 @@ export class ImpressionsStore {
   }
 
   getDashboardOpened() {
-    var k = store.get("dashboard_impressions");
-    return JSON.parse(k);
+    var impressions = store.get("dashboard_impressions");
+    return JSON.parse(impressions || "[]");
   }
 }