Skip to content

Commit 05e5b9e

Browse files
samejrmatt-aitken
authored andcommitted
Improved query performance
1 parent 6f55f89 commit 05e5b9e

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

apps/webapp/app/presenters/v3/LimitsPresenter.server.ts

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -147,12 +147,10 @@ export class LimitsPresenter extends BasePresenter {
147147
},
148148
});
149149

150-
// Get active branches count for this org
150+
// Get active branches count for this org (uses @@index([organizationId]))
151151
const activeBranchCount = await this._replica.runtimeEnvironment.count({
152152
where: {
153-
project: {
154-
organizationId,
155-
},
153+
organizationId,
156154
branchName: {
157155
not: null,
158156
},

0 commit comments

Comments
 (0)