We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 0bd2c7c commit 37e57eeCopy full SHA for 37e57ee
1 file changed
apps/sim/lib/mcp/service.ts
@@ -194,6 +194,7 @@ class McpService {
194
if (!userId || !config.workspaceId) {
195
throw new Error('OAuth MCP server requires both userId and workspaceId')
196
}
197
+ const workspaceId = config.workspaceId
198
199
// Load the row inside the refresh lock so concurrent callers observe tokens
200
// written by a predecessor refresh, rather than a stale snapshot. Without
@@ -204,7 +205,7 @@ class McpService {
204
205
const row = await getOrCreateOauthRow({
206
mcpServerId: config.id,
207
userId,
- workspaceId: config.workspaceId,
208
+ workspaceId,
209
})
210
if (!row.tokens) {
211
throw new McpOauthAuthorizationRequiredError(config.id, config.name)
0 commit comments