This repository was archived by the owner on May 18, 2026. It is now read-only.
Description 👟 Reproduction steps
Enable the Discord SSO with correct callback urls
👍 Expected behavior
SSO process should complete without issues. (Other IDPs are working as expected without issues)
👎 Actual Behavior
SSO fails to link accounts with error 500, docker console logs below.
[Nest] 45 - 10/29/2023, 6:34:12 PM ERROR [ExceptionsHandler] Cannot read properties of undefined (reading 'password')
TypeError: Cannot read properties of undefined (reading 'password')
at UserController.getCurrentUser (/opt/app/backend/dist/src/user/user.controller.js:32:38)
at /opt/app/backend/node_modules/@nestjs/core/router/router-execution-context.js:38:29
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
[Nest] 45 - 10/29/2023, 6:34:16 PM ERROR [ExceptionsHandler] Cannot read properties of undefined (reading 'password')
TypeError: Cannot read properties of undefined (reading 'password')
at UserController.getCurrentUser (/opt/app/backend/dist/src/user/user.controller.js:32:38)
at /opt/app/backend/node_modules/@nestjs/core/router/router-execution-context.js:38:29
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
[Nest] 45 - 10/29/2023, 6:34:16 PM ERROR [ExceptionsHandler] Cannot read properties of undefined (reading 'password')
TypeError: Cannot read properties of undefined (reading 'password')
at UserController.getCurrentUser (/opt/app/backend/dist/src/user/user.controller.js:32:38)
at /opt/app/backend/node_modules/@nestjs/core/router/router-execution-context.js:38:29
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
[Nest] 45 - 10/29/2023, 6:34:18 PM ERROR [ExceptionsHandler] Cannot read properties of undefined (reading 'password')
TypeError: Cannot read properties of undefined (reading 'password')
at UserController.getCurrentUser (/opt/app/backend/dist/src/user/user.controller.js:32:38)
at /opt/app/backend/node_modules/@nestjs/core/router/router-execution-context.js:38:29
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
[Nest] 45 - 10/29/2023, 6:34:19 PM ERROR [ExceptionsHandler] Cannot read properties of undefined (reading 'password')
TypeError: Cannot read properties of undefined (reading 'password')
at UserController.getCurrentUser (/opt/app/backend/dist/src/user/user.controller.js:32:38)
at /opt/app/backend/node_modules/@nestjs/core/router/router-execution-context.js:38:29
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
[Nest] 45 - 10/29/2023, 6:34:23 PM ERROR [ExceptionsHandler] Cannot read properties of undefined (reading 'password')
TypeError: Cannot read properties of undefined (reading 'password')
at UserController.getCurrentUser (/opt/app/backend/dist/src/user/user.controller.js:32:38)
at /opt/app/backend/node_modules/@nestjs/core/router/router-execution-context.js:38:29
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
[Nest] 45 - 10/29/2023, 6:34:24 PM ERROR [ExceptionsHandler] Cannot read properties of undefined (reading 'password')
TypeError: Cannot read properties of undefined (reading 'password')
at UserController.getCurrentUser (/opt/app/backend/dist/src/user/user.controller.js:32:38)
at /opt/app/backend/node_modules/@nestjs/core/router/router-execution-context.js:38:29
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
[Nest] 45 - 10/29/2023, 6:34:24 PM ERROR [ExceptionsHandler] Cannot read properties of undefined (reading 'password')
TypeError: Cannot read properties of undefined (reading 'password')
at UserController.getCurrentUser (/opt/app/backend/dist/src/user/user.controller.js:32:38)
at /opt/app/backend/node_modules/@nestjs/core/router/router-execution-context.js:38:29
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
[Nest] 45 - 10/29/2023, 6:34:35 PM ERROR [ExceptionsHandler]
Invalid `this.prisma.oAuthUser.create()` invocation in
/opt/app/backend/dist/src/oauth/oauth.service.js:77:37
74 `provider_${provider}`,
�������
75 ]);
76 }
→ 77 await this.prisma.oAuthUser.create({
data: {
userId: "bc026ba0-b75a-4eea-9200-d2349a8203f7",
provider: "discord",
providerUsername: undefined,
+ providerUserId: String
}
})
Argument `providerUserId` is missing.
PrismaClientValidationError:
Invalid `this.prisma.oAuthUser.create()` invocation in
/opt/app/backend/dist/src/oauth/oauth.service.js:77:37
74 `provider_${provider}`,
�������
75 ]);
76 }
→ 77 await this.prisma.oAuthUser.create({
data: {
userId: "bc026ba0-b75a-4eea-9200-d2349a8203f7",
provider: "discord",
providerUsername: undefined,
+ providerUserId: String
}
})
Argument `providerUserId` is missing.
at Ur (/opt/app/backend/node_modules/@prisma/client/runtime/library.js:115:5803)
at zr.handleRequestError (/opt/app/backend/node_modules/@prisma/client/runtime/library.js:122:8007)
at zr.handleAndLogRequestError (/opt/app/backend/node_modules/@prisma/client/runtime/library.js:122:7697)
at zr.request (/opt/app/backend/node_modules/@prisma/client/runtime/library.js:122:7307)
at async OAuthService.link (/opt/app/backend/dist/src/oauth/oauth.service.js:77:9)
at async OAuthController.callback (/opt/app/backend/dist/src/oauth/oauth.controller.js:53:13)
🌐 Browser
Firefox & Safari (MacOS)
Reactions are currently unavailable
👟 Reproduction steps
Enable the Discord SSO with correct callback urls
👍 Expected behavior
SSO process should complete without issues. (Other IDPs are working as expected without issues)
👎 Actual Behavior
SSO fails to link accounts with error 500, docker console logs below.
🌐 Browser
Firefox & Safari (MacOS)