Skip to content

Commit 28150b5

Browse files
comment about hack
1 parent d21e3aa commit 28150b5

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

packages/backend/src/ee/accountPermissionSyncer.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -161,6 +161,8 @@ export class AccountPermissionSyncer {
161161
throw new Error(`User '${account.user.email}' does not have an GitHub OAuth access token associated with their GitHub account.`);
162162
}
163163

164+
// @hack: we don't have a way of identifying specific identity providers in the config file.
165+
// Instead, we'll use the first connection of type 'github' and hope for the best.
164166
const baseUrl = Array.from(Object.values(config.connections ?? {}))
165167
.find(connection => connection.type === 'github')?.url;
166168

@@ -189,6 +191,8 @@ export class AccountPermissionSyncer {
189191
throw new Error(`User '${account.user.email}' does not have a GitLab OAuth access token associated with their GitLab account.`);
190192
}
191193

194+
// @hack: we don't have a way of identifying specific identity providers in the config file.
195+
// Instead, we'll use the first connection of type 'gitlab' and hope for the best.
192196
const baseUrl = Array.from(Object.values(config.connections ?? {}))
193197
.find(connection => connection.type === 'gitlab')?.url
194198

0 commit comments

Comments
 (0)