Przeglądaj źródła

currentBoard is very often called in jade files, so use there the cache too

Martin Filser 2 lat temu
rodzic
commit
30d154724a
1 zmienionych plików z 3 dodań i 1 usunięć
  1. 3 1
      client/lib/utils.js

+ 3 - 1
client/lib/utils.js

@@ -1,3 +1,5 @@
+import { ReactiveCache } from '/imports/reactiveCache';
+
 Utils = {
   setBackgroundImage(url) {
     const currentBoard = Boards.findOne(Session.get('currentBoard'));
@@ -36,7 +38,7 @@ Utils = {
    */
   getCurrentBoard() {
     const boardId = Utils.getCurrentBoardId();
-    const ret = Boards.findOne(boardId);
+    const ret = ReactiveCache.getBoard(boardId);
     return ret;
   },
   getCurrentCard(ignorePopupCard) {