fix(integrations): don't filter per-user connections out of existing lookups

This commit is contained in:
Philipinho
2026-05-23 02:04:47 +01:00
parent 7e1bef8b7e
commit 0d58b88db8
@@ -35,7 +35,6 @@ export class IntegrationConnectionRepo {
.selectAll()
.where('integrationId', '=', integrationId)
.where('userId', '=', userId)
.where('kind', '=', 'workspace')
.executeTakeFirst();
}
@@ -58,7 +57,6 @@ export class IntegrationConnectionRepo {
.where('integrations.type', '=', integrationType)
.where('integrations.deletedAt', 'is', null)
.where('integrationConnections.userId', '=', userId)
.where('integrationConnections.kind', '=', 'workspace')
.executeTakeFirst();
}
@@ -160,7 +158,6 @@ export class IntegrationConnectionRepo {
.where('refreshToken', 'is not', null)
.where('tokenExpiresAt', 'is not', null)
.where('tokenExpiresAt', '<', threshold)
.where('kind', '=', 'workspace')
.execute();
}