fix: replace all any request types with typed AuthRequest interface#30
Open
karanjadavi wants to merge 2 commits into
Open
fix: replace all any request types with typed AuthRequest interface#30karanjadavi wants to merge 2 commits into
karanjadavi wants to merge 2 commits into
Conversation
- Add shared JwtUser and AuthRequest interfaces in src/common/types/auth-request.interface.ts - Update JwtStrategy.validate() to return typed JwtUser with sub field - Replace @request() req: any across users, admin, milestones, campaigns controllers - Replace @Req() req: Request & { user: any } in donations, notifications, api-keys controllers - Add AuthenticatedSocket interface in notifications.gateway.ts to remove (client as any) casts - Replace as any casts in users.service.ts with Prisma.InputJsonValue and typed assertions - Replace as any casts in campaigns.service.ts with Number(), Prisma.EnumCampaignStatusFilter, and type guard - Fix soroban.service.ts XDR response casts and scValResult double-cast via unknown - Fix email.service.ts (info as any).message with narrowed type - Enable @typescript-eslint/no-explicit-any: error in eslint.config.mjs to prevent regressions Closes OrbitChainLabs#17
Contributor
|
@karanjadavi please fix the CI. |
Contributor
|
Direction is good — typed AuthRequest is a real improvement. Heads up: CI is red on lint/build, so flipping |
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.
Closes #17