소스 검색

HUE-7949 [dashboard] Avoid breaking the dashboard if the collection name is missing

Enrico Berti 7 년 전
부모
커밋
78a55f8
1개의 변경된 파일4개의 추가작업 그리고 0개의 파일을 삭제
  1. 4 0
      desktop/core/src/desktop/templates/assist.mako

+ 4 - 0
desktop/core/src/desktop/templates/assist.mako

@@ -2947,6 +2947,10 @@ from desktop.views import _ko
         var activeDashboardCollection = huePubSub.subscribe('set.active.dashboard.collection', function(collection) {
           var collectionName = collection.name();
 
+          if (!collectionName) {
+            return;
+          }
+
           var assistDbSource = new AssistDbSource({
             i18n : i18n,
             type: collection.engine(),