summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authoreug-vs <eug-vs@keemail.me>2021-04-24 20:20:54 +0300
committereug-vs <eug-vs@keemail.me>2021-04-24 20:20:54 +0300
commit874b97bc01b691d7a4553c0ffb337bfaa003d1ff (patch)
tree8590bd3fb89dd6cf92776341ac6a7673857dee3c
parentc4459ed5fac54f390fd5387988556d279403d490 (diff)
downloadcommercel-api-874b97bc01b691d7a4553c0ffb337bfaa003d1ff.tar.gz
feat: enable regex search in Contractors
-rw-r--r--src/services/contractors.service.ts4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/services/contractors.service.ts b/src/services/contractors.service.ts
index a5b3f59..1bfc03d 100644
--- a/src/services/contractors.service.ts
+++ b/src/services/contractors.service.ts
@@ -2,9 +2,9 @@ import { Application } from '@feathersjs/express';
import service from 'feathers-mongoose';
import Model from '../models/contractor/contractor.model';
-const contractors = service({ Model });
+const Contractors = service({ Model, whitelist: ['$options', '$regex'] });
export default (app: Application): void => {
- app.use('/contractors', contractors);
+ app.use('/contractors', Contractors);
};