Skip to content

Commit

Permalink
refactor: update optional parameters
Browse files Browse the repository at this point in the history
  • Loading branch information
vplasencia committed Feb 6, 2024
1 parent 6d38f55 commit 9ab8978
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion apps/api/src/app/credentials/credentials.controller.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@ export class CredentialsController {
@Body() dto: AddMemberDto
): Promise<void | any> {
return this.credentialsService.addMember(
dto.oAuthCode,
dto.oAuthState,
dto.oAuthCode,
dto.address,
dto.network,
dto.blockNumber
Expand Down
6 changes: 3 additions & 3 deletions apps/api/src/app/credentials/dto/add-member.dto.ts
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
import { IsString, IsOptional } from "class-validator"

export class AddMemberDto {
@IsOptional()
@IsString()
readonly oAuthCode: string
readonly oAuthState: string

@IsOptional()
@IsString()
readonly oAuthState: string
readonly oAuthCode: string

@IsOptional()
@IsString()
Expand Down
6 changes: 3 additions & 3 deletions apps/dashboard/src/api/bandadaAPI.ts
Original file line number Diff line number Diff line change
Expand Up @@ -248,9 +248,9 @@ export async function setOAuthState(
*/
export async function addMemberByCredentials(
oAuthState: string,
oAuthCode: string,
address: string,
network: string,
oAuthCode?: string,
address?: string,
network?: string,
blockNumber?: string
): Promise<string | null> {
try {
Expand Down

0 comments on commit 9ab8978

Please sign in to comment.