From 90be4200ca2578fe6b7f516b6c2b427e4875694a Mon Sep 17 00:00:00 2001 From: Philipp Dormann Date: Tue, 22 Dec 2020 18:16:08 +0100 Subject: [PATCH] =?UTF-8?q?=F0=9F=A7=A0=20logic=20cleanup=20in=20Login=20c?= =?UTF-8?q?omponent?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/Login.svelte | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/src/components/Login.svelte b/src/components/Login.svelte index c3992749..b3e4fc55 100644 --- a/src/components/Login.svelte +++ b/src/components/Login.svelte @@ -3,14 +3,12 @@ import { _ } from "svelte-i18n"; store.init(); import { push, pop, replace } from "svelte-spa-router"; - // import { OpenAPI, AuthService } from "@odit/lfk-client-js"; OpenAPI.BASE = config.baseurl; - // import Toastify from "toastify-js"; import "toastify-js/src/toastify.css"; - let usersUsername, - usersPassword = ""; + let usersUsername; + let usersPassword = ""; let last_loginclick_processed = true; const login = async () => { @@ -23,10 +21,10 @@ }).showToast(); let username = usersUsername; let password = usersPassword; - // if (usersUsername.length == 0) { + // if ((usersUsername + "").length == 0) { username = config.fallback_username || "demo"; // } - // if (usersPassword.length == 0) { + // if ((usersPassword + "").length == 0) { password = config.fallback_password || "demo"; // } AuthService.authControllerLogin({