File tree Expand file tree Collapse file tree
packages/app/control/src/app/(auth)/(oauth)/api/oauth/token Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -125,7 +125,7 @@ export async function handleIssueToken(
125125 } ,
126126 } ) ;
127127 userRole = AppRole . CUSTOMER ;
128- } catch ( error ) {
128+ } catch {
129129 throw new Error ( 'Error creating app membership' ) ;
130130 }
131131 }
Original file line number Diff line number Diff line change @@ -39,10 +39,8 @@ export const POST = createZodRoute()
3939
4040 switch ( body . grant_type ) {
4141 case 'authorization_code' : {
42- const { grant_type, ...issueTokenBody } = body ;
43-
4442 try {
45- const result = await handleIssueToken ( issueTokenBody , metadata ) ;
43+ const result = await handleIssueToken ( body , metadata ) ;
4644 return NextResponse . json ( result ) ;
4745 } catch ( error ) {
4846 const message =
@@ -58,10 +56,8 @@ export const POST = createZodRoute()
5856 }
5957 }
6058 case 'refresh_token' : {
61- const { grant_type, ...refreshTokenBody } = body ;
62-
6359 try {
64- const result = await handleRefreshToken ( refreshTokenBody , metadata ) ;
60+ const result = await handleRefreshToken ( body , metadata ) ;
6561 return NextResponse . json ( result ) ;
6662 } catch ( error ) {
6763 const message =
You can’t perform that action at this time.
0 commit comments