소스 검색

Fix board query

Justin Reynolds 5 년 전
부모
커밋
b31a74e9af
1개의 변경된 파일1개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 1
      server/publications/boards.js

+ 1 - 1
server/publications/boards.js

@@ -9,7 +9,7 @@ Meteor.publish('boards', function() {
 
   // Defensive programming to verify that starredBoards has the expected
   // format -- since the field is in the `profile` a user can modify it.
-  const { starredBoards = [] } = Users.findOne(this.userId).profile || {};
+  const { starredBoards = [] } = Users.findOne(this.userId).profile || [];
   check(starredBoards, [String]);
 
   return Boards.find(