From e7e90bdf6e99d8e7b60e64015819543d706f5b2d Mon Sep 17 00:00:00 2001 From: Mateusz779 Date: Thu, 13 Apr 2023 12:06:23 +0200 Subject: [PATCH] mod template --- app.py | 3 +-- templates/login.html | 1 + 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/app.py b/app.py index 0dafdb9..ca069e6 100644 --- a/app.py +++ b/app.py @@ -30,8 +30,7 @@ def login_post(): auth_token = db.login(username, password) if auth_token is None: - flash('Nieprawidłowa nazwa użytkownika lub hasło.', 'error') - return redirect(url_for('/')) + return render_template('login.html', incorrect="Incorrect username or password!") response = make_response(render_template('index.html')) response.set_cookie('auth_token', auth_token) diff --git a/templates/login.html b/templates/login.html index db1b17e..22d0a45 100644 --- a/templates/login.html +++ b/templates/login.html @@ -57,6 +57,7 @@ +

{{incorrect}}