Skip to content

Commit 95c2792

Browse files
committed
fix
1 parent f9ee805 commit 95c2792

File tree

2 files changed

+8
-1
lines changed
  • apps/sim
    • app/workspace/[workspaceId]/w/[workflowId]/components/panel/components/deploy/components/deploy-modal
    • hooks/queries

2 files changed

+8
-1
lines changed

apps/sim/app/workspace/[workspaceId]/w/[workflowId]/components/panel/components/deploy/components/deploy-modal/deploy-modal.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -658,7 +658,7 @@ export function DeployModal({
658658
onClick={handleMcpToolFormSubmit}
659659
disabled={mcpToolSubmitting || !mcpToolCanSave}
660660
>
661-
{mcpToolSubmitting ? 'Saving...' : 'Save Tool Schema'}
661+
{mcpToolSubmitting ? 'Saving...' : 'Save Tool'}
662662
</Button>
663663
</div>
664664
</ModalFooter>

apps/sim/hooks/queries/forms.ts

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -189,6 +189,10 @@ export function useCreateForm() {
189189
const data = await response.json()
190190

191191
if (!response.ok) {
192+
// Handle specific error cases
193+
if (data.error === 'Identifier already in use') {
194+
throw new Error('This identifier is already in use')
195+
}
192196
throw new Error(data.error || 'Failed to create form')
193197
}
194198

@@ -233,6 +237,9 @@ export function useUpdateForm() {
233237
const result = await response.json()
234238

235239
if (!response.ok) {
240+
if (result.error === 'Identifier already in use') {
241+
throw new Error('This identifier is already in use')
242+
}
236243
throw new Error(result.error || 'Failed to update form')
237244
}
238245

0 commit comments

Comments
 (0)