diff --git a/src/components/Logs.tsx b/src/components/Logs.tsx index ec31ab96f..ff7a7ce55 100644 --- a/src/components/Logs.tsx +++ b/src/components/Logs.tsx @@ -6,8 +6,6 @@ import { InfoBox, InnerCard, NiceP, - SimpleDialog, - TextField, VStack } from "~/components"; import { useI18n } from "~/i18n/context"; @@ -18,13 +16,11 @@ export function Logs() { // Create state for errors, password and dialog visibility const [error, setError] = createSignal(); - const [exportDecrypt, setExportDecrypt] = createSignal(false); - const [password, setPassword] = createSignal(); async function handleSave() { try { setError(undefined); - const logs = await MutinyWallet.get_logs(password()); // Use password if required + const logs = await MutinyWallet.get_logs(); await downloadTextFile( logs.join("") || "", "mutiny-logs.txt", @@ -32,26 +28,10 @@ export function Logs() { ); } catch (e) { console.error(e); - const err = eify(e); - if (err.message === "Incorrect password entered.") { - setExportDecrypt(true); - } else { - setError(err); - } + setError(eify(e)); } } - function savePassword(e: Event) { - e.preventDefault(); - handleSave(); - setPassword(undefined); // clear password after use - setExportDecrypt(false); // close the dialog - } - - function noop() { - // noop - } - return ( @@ -65,33 +45,6 @@ export function Logs() { {error()?.message} - -
-
- setPassword(e.currentTarget.value)} - error={""} - onBlur={noop} - onChange={noop} - /> - - {error()?.message} - - -
-
-
); }