From 2879dcc157c40e89687aadc427b8f6f5613a68b4 Mon Sep 17 00:00:00 2001 From: Benjamin Janssens Date: Thu, 14 Aug 2025 14:47:15 +0200 Subject: [PATCH] feat(catalog): map organizations to lower case Signed-off-by: Benjamin Janssens --- .../src/providers/GithubEntityProvider.ts | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/plugins/catalog-backend-module-github/src/providers/GithubEntityProvider.ts b/plugins/catalog-backend-module-github/src/providers/GithubEntityProvider.ts index 440ccaadf5..e6f69d4918 100644 --- a/plugins/catalog-backend-module-github/src/providers/GithubEntityProvider.ts +++ b/plugins/catalog-backend-module-github/src/providers/GithubEntityProvider.ts @@ -348,7 +348,9 @@ export class GithubEntityProvider implements EntityProvider, EventSubscriber { } private async onPush(event: PushEvent) { - const organizations = await this.getOrganizations(); // TODO: make sure they are lowercase + const organizations = (await this.getOrganizations()).map(org => + org.toLocaleLowerCase('en-US'), + ); const eventOrganization = event.organization?.login.toLocaleLowerCase('en-US'); @@ -435,7 +437,9 @@ export class GithubEntityProvider implements EntityProvider, EventSubscriber { } private async onRepoChange(event: RepositoryEvent) { - const organizations = await this.getOrganizations(); // TODO: make sure they are lowercase + const organizations = (await this.getOrganizations()).map(org => + org.toLocaleLowerCase('en-US'), + ); const eventOrganization = event.organization?.login.toLocaleLowerCase('en-US');