summaryrefslogtreecommitdiff
path: root/packages/backend/src/core/SearchService.ts
diff options
context:
space:
mode:
authorsyuilo <Syuilotan@yahoo.co.jp>2023-07-08 16:53:07 +0900
committersyuilo <Syuilotan@yahoo.co.jp>2023-07-08 16:53:07 +0900
commit081a14d6f3ca3664aabdd06aaf06080dcba17c25 (patch)
tree901a7a55b38b83be49ace77c8d9f1d27a85054c8 /packages/backend/src/core/SearchService.ts
parentuse node 20.3.1 (diff)
downloadsharkey-081a14d6f3ca3664aabdd06aaf06080dcba17c25.tar.gz
sharkey-081a14d6f3ca3664aabdd06aaf06080dcba17c25.tar.bz2
sharkey-081a14d6f3ca3664aabdd06aaf06080dcba17c25.zip
perf(backend): use limit() instead of take()
Diffstat (limited to 'packages/backend/src/core/SearchService.ts')
-rw-r--r--packages/backend/src/core/SearchService.ts2
1 files changed, 1 insertions, 1 deletions
diff --git a/packages/backend/src/core/SearchService.ts b/packages/backend/src/core/SearchService.ts
index 9502afcc9b..956c4cc09c 100644
--- a/packages/backend/src/core/SearchService.ts
+++ b/packages/backend/src/core/SearchService.ts
@@ -174,7 +174,7 @@ export class SearchService {
if (me) this.queryService.generateMutedUserQuery(query, me);
if (me) this.queryService.generateBlockedUserQuery(query, me);
- return await query.take(pagination.limit).getMany();
+ return await query.limit(pagination.limit).getMany();
}
}
}