소스 검색

Fix errant escape-string-regexp importing

Denis Perov 3 년 전
부모
커밋
1b83399236
2개의 변경된 파일3개의 추가작업 그리고 3개의 파일을 삭제
  1. 2 1
      models/cardComments.js
  2. 1 2
      server/publications/cards.js

+ 2 - 1
models/cardComments.js

@@ -1,4 +1,5 @@
-const escapeForRegex = require('escape-string-regexp');
+import escapeForRegex from 'escape-string-regexp';
+
 CardComments = new Mongo.Collection('card_comments');
 CardComments = new Mongo.Collection('card_comments');
 
 
 /**
 /**

+ 1 - 2
server/publications/cards.js

@@ -1,4 +1,5 @@
 import moment from 'moment';
 import moment from 'moment';
+import escapeForRegex from 'escape-string-regexp';
 import Users from '../../models/users';
 import Users from '../../models/users';
 import Boards from '../../models/boards';
 import Boards from '../../models/boards';
 import Lists from '../../models/lists';
 import Lists from '../../models/lists';
@@ -52,8 +53,6 @@ import { CARD_TYPES } from '../../config/const';
 import Org from "../../models/org";
 import Org from "../../models/org";
 import Team from "../../models/team";
 import Team from "../../models/team";
 
 
-const escapeForRegex = require('escape-string-regexp');
-
 Meteor.publish('card', cardId => {
 Meteor.publish('card', cardId => {
   check(cardId, String);
   check(cardId, String);
   const ret = Cards.find({ _id: cardId });
   const ret = Cards.find({ _id: cardId });