From 29deb0e5e537d276285e73db13f7b40a8a817df9 Mon Sep 17 00:00:00 2001 From: Vivian Plasencia Date: Mon, 4 Mar 2024 12:44:41 +0100 Subject: [PATCH 1/2] refactor: update code comments --- apps/api/src/app/credentials/credentials.service.ts | 5 ++++- apps/dashboard/src/pages/credentials.tsx | 6 ++---- 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/apps/api/src/app/credentials/credentials.service.ts b/apps/api/src/app/credentials/credentials.service.ts index 50d12b27..7596923a 100644 --- a/apps/api/src/app/credentials/credentials.service.ts +++ b/apps/api/src/app/credentials/credentials.service.ts @@ -75,8 +75,11 @@ export class CredentialsService { /** * Add a member to the credential group if they meet the right credential criteria. - * @param oAuthCode OAuth code to exchange for an access token. * @param OAuthState OAuth state to prevent forgery attacks. + * @param oAuthCode OAuth code to exchange for an access token. + * @param address Account address. + * @param network Network. + * @param blockNumber Block number. * @returns Redirect URI */ async addMember( diff --git a/apps/dashboard/src/pages/credentials.tsx b/apps/dashboard/src/pages/credentials.tsx index 2338ec35..55daf767 100644 --- a/apps/dashboard/src/pages/credentials.tsx +++ b/apps/dashboard/src/pages/credentials.tsx @@ -64,7 +64,7 @@ export default function CredentialsPage() { if (state && admin && network) { const redirectUrl = await addMemberByCredentials( state, - "", + undefined, admin.address, network, blockNumberVal @@ -108,9 +108,7 @@ export default function CredentialsPage() { const clientRedirectUri = await addMemberByCredentials( oAuthState, - oAuthCode, - "", - "" + oAuthCode ) if (clientRedirectUri) { From 9f079d7aed7c884f20fdadd64ea183ef9cb20dfc Mon Sep 17 00:00:00 2001 From: Vivian Plasencia Date: Mon, 4 Mar 2024 12:51:17 +0100 Subject: [PATCH 2/2] docs: update add member function docs --- apps/api/src/app/credentials/credentials.service.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apps/api/src/app/credentials/credentials.service.ts b/apps/api/src/app/credentials/credentials.service.ts index 7596923a..d82f975f 100644 --- a/apps/api/src/app/credentials/credentials.service.ts +++ b/apps/api/src/app/credentials/credentials.service.ts @@ -78,7 +78,7 @@ export class CredentialsService { * @param OAuthState OAuth state to prevent forgery attacks. * @param oAuthCode OAuth code to exchange for an access token. * @param address Account address. - * @param network Network. + * @param network Network name. * @param blockNumber Block number. * @returns Redirect URI */