Skip to content

Commit 9671131

Browse files
waleedlatif1claude
andcommitted
fix(mcp): normalize empty/null when detecting OAuth client id change
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
1 parent f39abd9 commit 9671131

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

  • apps/sim/app/api/mcp/servers/[id]

apps/sim/app/api/mcp/servers/[id]/route.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -142,7 +142,8 @@ export const PATCH = withRouteHandler(
142142

143143
const urlChanged = body.url !== undefined && currentServer?.url !== body.url
144144
const clientIdChanged =
145-
body.oauthClientId !== undefined && currentServer?.oauthClientId !== body.oauthClientId
145+
body.oauthClientId !== undefined &&
146+
(body.oauthClientId || null) !== (currentServer?.oauthClientId ?? null)
146147
let clientSecretChanged = false
147148
if (oauthClientSecret !== undefined) {
148149
if (!oauthClientSecret) {

0 commit comments

Comments
 (0)