From 67806440792cbfb383f599f8341fef6507dfc6c9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fredrik=20Adel=C3=B6w?= Date: Sat, 14 Feb 2026 17:00:19 +0100 Subject: [PATCH] copilot comments MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Fredrik Adelöw --- .changeset/metal-trains-smell-1.md | 2 +- packages/catalog-client/src/types/api.ts | 2 +- plugins/catalog-backend/src/service/DefaultLocationService.ts | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.changeset/metal-trains-smell-1.md b/.changeset/metal-trains-smell-1.md index 4a4db1dd6e..2bf814bbf5 100644 --- a/.changeset/metal-trains-smell-1.md +++ b/.changeset/metal-trains-smell-1.md @@ -2,4 +2,4 @@ '@backstage/plugin-catalog-backend': minor --- -Implemented the `POST /locations/by-query` endpoints that allows paginated, filtered location queries +Implemented the `POST /locations/by-query` endpoint which allows paginated, filtered location queries diff --git a/packages/catalog-client/src/types/api.ts b/packages/catalog-client/src/types/api.ts index c1f75f2c79..12c5e00c03 100644 --- a/packages/catalog-client/src/types/api.ts +++ b/packages/catalog-client/src/types/api.ts @@ -697,7 +697,7 @@ export interface CatalogApi { * * ``` * const secondBatchResponse = await catalogClient - * .queryLocations({ cursor: response.nextCursor }); + * .queryLocations({ cursor: response.pageInfo.nextCursor }); * ``` * * `secondBatchResponse` will contain the next batch of (maximum) 20 locations, diff --git a/plugins/catalog-backend/src/service/DefaultLocationService.ts b/plugins/catalog-backend/src/service/DefaultLocationService.ts index f65ff18271..ad3044ffd9 100644 --- a/plugins/catalog-backend/src/service/DefaultLocationService.ts +++ b/plugins/catalog-backend/src/service/DefaultLocationService.ts @@ -76,7 +76,7 @@ export class DefaultLocationService implements LocationService { async queryLocations(options: { limit: number; - afterId: string; + afterId?: string; query?: FilterPredicate; credentials: BackstageCredentials; }): Promise<{ items: Location[]; totalItems: number }> {