From 3c4ef9463599537c44a9e1a7f38470fee7368f5a Mon Sep 17 00:00:00 2001 From: eug-vs Date: Mon, 10 May 2021 23:11:38 +0300 Subject: fix: use correct find syntax --- src/services/uploads.service.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/services/uploads.service.ts b/src/services/uploads.service.ts index 9a61a50..cb9ebc6 100644 --- a/src/services/uploads.service.ts +++ b/src/services/uploads.service.ts @@ -34,7 +34,7 @@ const parseAccountId = (rows: any[], context: HookContext) => { return context.app .service('accounts') - .find({ code }) + .find({ query: { code } }) .then((results: any[]) => { if (results.length) return results[0]; return context.app @@ -85,7 +85,7 @@ const parseTransfersBill = async (context: HookContext): Promise => const contractorId = await context.app .service('contractors') - .find({ vatId }) + .find({ query: { vatId } }) .then((results: any[]) => { if (results.length) return results[0]; return context.app -- cgit v1.2.3