fix(policies): remove stray brace breaking nest build#2614
Merged
Conversation
Commit 91c6deb added the approver-id authorization check to approveChanges but left an extra closing brace after the if block, which prematurely closed the !policy.pendingVersionId guard and the method, putting every subsequent method at class-statement scope. That cascaded into 131 tsc errors and broke the prod Docker build. Delete the stray brace. Nothing else changes. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Contributor
|
🎉 This PR is included in version 3.26.1 🎉 The release is available on GitHub release Your semantic-release bot 📦🚀 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
approveChangesbut left an extra}after the innerifblock, prematurely closing the outer!policy.pendingVersionIdguard and the method itself.denyChanges,getMemberId,hexToRgb,downloadAllPoliciesPdf,isUniqueConstraintError, …) ended up at class-statement scope, cascading into 131 tsc errors and breaking the production Docker build (bunx nest build).Test plan
bunx nest buildlocally: 131 errors → 1 pre-existing unrelatedbetter-authtype error onauth.server.ts:430Follow-up
denyChangeshas the same stale-state cleanup pattern asapproveChangesand still needs the matchingdto.approverId === policy.approverIdguard to fully address the original cubic P2. Will do that in a separate PR.🤖 Generated with Claude Code
Summary by cubic
Remove an extra closing brace in
PoliciesService.approveChangesthat pushed subsequent methods to class scope, causing 131 TypeScript errors and failingbunx nest build. Restores the build; no behavior change.Written for commit fde65bf. Summary will update on new commits.