diff --git a/app/components/settings/Settings.tsx b/app/components/settings/Settings.tsx index d0f769b..87b05b6 100644 --- a/app/components/settings/Settings.tsx +++ b/app/components/settings/Settings.tsx @@ -12,9 +12,11 @@ import PrivacySettings from './PrivacySettings'; import FontSizeSetting from './FontSize'; import OpenSourceModeToggle from './OpenSourceToggle'; import { + changeHistory, changeSettings, createAccount, deleteAccount, + getHistory, } from '../../backend/database'; import ThemeDropdown from './DropDownTheme'; @@ -372,7 +374,11 @@ const Settings: React.FC<{ closeSettings: () => void; accountName: string }> = ( localStorage.setItem("currentEmail", useEmail) alert('Account successfully changed!') window.location.reload() + } else { + alert("failed to send settings") } + } else { + alert("failed to create account") } } }; @@ -409,7 +415,7 @@ const Settings: React.FC<{ closeSettings: () => void; accountName: string }> = ( checked={myBoolean} setChecked={setMyBoolean} /> - void; accountName: string }> = ( onClick={handleLogout} // Function to call on click className="update-credentials-button" // Custom styling class /> +

WARNING: Will delete your chat history.