فهرست منبع

Merge pull request #2657 from justinr1234/patch-6

Fix last label undefined
Lauri Ojansivu 6 سال پیش
والد
کامیت
828822daad
1فایلهای تغییر یافته به همراه1 افزوده شده و 1 حذف شده
  1. 1 1
      client/components/activities/activities.js

+ 1 - 1
client/components/activities/activities.js

@@ -85,7 +85,7 @@ BlazeComponent.extendComponent({
     const lastLabel = Boards.findOne(Session.get('currentBoard')).getLabelById(
       lastLabelId,
     );
-    if (lastLabel.name === undefined || lastLabel.name === '') {
+    if (lastLabel && (lastLabel.name === undefined || lastLabel.name === '')) {
       return lastLabel.color;
     } else {
       return lastLabel.name;