From c231cb73278c5553e3ca7a1ab820c49ea515070d Mon Sep 17 00:00:00 2001 From: Muhammad Aaqil Date: Mon, 18 Aug 2025 20:20:36 +0500 Subject: [PATCH] fix: pass options to repository methods Signed-off-by: Muhammad Aaqil --- packages/rest-crud/src/crud-rest.controller.ts | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/packages/rest-crud/src/crud-rest.controller.ts b/packages/rest-crud/src/crud-rest.controller.ts index 0b8446712c9c..8240dea630b2 100644 --- a/packages/rest-crud/src/crud-rest.controller.ts +++ b/packages/rest-crud/src/crud-rest.controller.ts @@ -164,7 +164,7 @@ export function defineCrudRestController< @param.filter(modelCtor) filter?: Filter, ): Promise<(T & Relations)[]> { - return this.repository.find(filter); + return this.repository.find(filter, options); } @get('/{id}', { @@ -190,7 +190,7 @@ export function defineCrudRestController< @param.where(modelCtor) where?: Where, ): Promise { - return this.repository.count(where); + return this.repository.count(where, options); } } @@ -234,6 +234,7 @@ export function defineCrudRestController< // with no explicit type-casts required data as DataObject, where, + options, ); }