{"record":{"id":"801346e8014bd195","repo":"diegosouzapw/OmniRoute","slug":"failed-to-save-auto-disable-config","errorCode":null,"errorMessage":"Failed to save auto-disable config","messagePattern":"Failed to save auto-disable config","errorType":"exception","errorClass":"Error","httpStatus":null,"severity":"error","filePath":"src/app/(dashboard)/dashboard/settings/components/AutoDisableCard.tsx","lineNumber":65,"sourceCode":"      .then((res) => res.json())\n      .then((json) => {\n        const next = normalizeForm(json);\n        setData(next);\n        setDraft(next);\n        setLoading(false);\n      })\n      .catch(() => setLoading(false));\n  }, []);\n\n  const handleSave = async () => {\n    setSaving(true);\n    try {\n      const res = await fetch(\"/api/settings/auto-disable-accounts\", {\n        method: \"PUT\",\n        headers: { \"Content-Type\": \"application/json\" },\n        body: JSON.stringify(draft),\n      });\n      if (!res.ok) throw new Error(\"Failed to save auto-disable config\");\n      const savedData = normalizeForm(await res.json());\n      setData(savedData);\n      setEditMode(false);\n      notify.success(t(\"savedSuccessfully\"));\n    } catch (err) {\n      notify.error(err instanceof Error ? err.message : \"Error saving\");\n    } finally {\n      setSaving(false);\n    }\n  };\n\n  if (loading) return null;\n\n  const current = editMode ? draft : data;\n  const scopes = AUTO_DISABLE_BANNED_SCOPES;\n\n  return (\n    <Card className=\"p-0 overflow-hidden\">","sourceCodeStart":47,"sourceCodeEnd":83,"githubUrl":"https://github.com/diegosouzapw/OmniRoute/blob/a179ffed5bb2e0b883b9ae7214ce8717b2a94c4d/src/app/(dashboard)/dashboard/settings/components/AutoDisableCard.tsx#L47-L83","documentation":"Error \"Failed to save auto-disable config\" thrown in diegosouzapw/OmniRoute.","triggerScenarios":"Thrown at src/app/(dashboard)/dashboard/settings/components/AutoDisableCard.tsx:65 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":[],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"a179ffed5bb2e0b883b9ae7214ce8717b2a94c4d","analyzedAt":"2026-08-25T18:35:09.898Z","schemaVersion":2},"datasetVersion":"2026-08-25T21:54:21.419Z"}