Skip to content

Commit 273ff94

Browse files
ryan-willisCopilot
andauthored
safer mcp url match
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
1 parent 9232aa5 commit 273ff94

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

packages/insomnia/src/common/import.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -831,7 +831,7 @@ export async function findExistingImportedMcp(projectId?: string, organizationId
831831
const workspaces = await services.workspace.listByParentId(pid);
832832
for (const ws of workspaces.filter(models.workspace.isMcp)) {
833833
const mcpRequest = await services.mcpRequest.getByParentId(ws._id);
834-
if (mcpRequest?.url.trim() === incomingUrl) {
834+
if (mcpRequest?.url?.trim() === incomingUrl) {
835835
return { workspace: ws, mcpRequest };
836836
}
837837
}

0 commit comments

Comments
 (0)