diff --git a/src/lib/apis/auths/index.ts b/src/lib/apis/auths/index.ts index a690a476b..b703e8746 100644 --- a/src/lib/apis/auths/index.ts +++ b/src/lib/apis/auths/index.ts @@ -342,7 +342,7 @@ export const createApiKey = async (token: string) => { throw error; } return res; -} +}; export const getApiKey = async (token: string) => { let error = null; @@ -367,7 +367,7 @@ export const getApiKey = async (token: string) => { throw error; } return res; -} +}; export const deleteApiKey = async (token: string) => { let error = null; @@ -392,4 +392,4 @@ export const deleteApiKey = async (token: string) => { throw error; } return res; -} +}; diff --git a/src/lib/components/chat/Settings/Account.svelte b/src/lib/components/chat/Settings/Account.svelte index fbb5e6289..f368d90f9 100644 --- a/src/lib/components/chat/Settings/Account.svelte +++ b/src/lib/components/chat/Settings/Account.svelte @@ -17,7 +17,7 @@ let name = ''; let showJWTToken = false; let JWTTokenCopied = false; - let showApiKey= false; + let showApiKey = false; let ApiKeyCopied = false; let localApiKey = localStorage.apiKey; let profileImageInputElement: HTMLInputElement; @@ -39,12 +39,11 @@ const createApiKeyHandler = async () => { const apiKey = await createApiKey(localStorage.token); if (apiKey) { - localApiKey = apiKey["api_key"]; + localApiKey = apiKey['api_key']; localStorage.apiKey = localApiKey; toast.success($i18n.t('API Key created.')); } else { toast.error($i18n.t('Failed to create API Key.')); - } }; @@ -186,9 +185,9 @@