From 6103b1fd221ae115e10059f803ef35b211305e78 Mon Sep 17 00:00:00 2001 From: pi3c Date: Wed, 11 Oct 2023 09:49:40 +0300 Subject: [PATCH] fix 404 --- pyproger/errors/routes.py | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/pyproger/errors/routes.py b/pyproger/errors/routes.py index 72cc9d0..60a7305 100755 --- a/pyproger/errors/routes.py +++ b/pyproger/errors/routes.py @@ -1,4 +1,4 @@ -from flask import render_template, url_for +from flask import current_app, render_template from . import bp @@ -8,8 +8,12 @@ def handle_404(err): return ( render_template( "errors/404.html", - title="pyproger - Страница не найдена", - menu_title="pyproger", + title=f'{current_app.config.get("BRAND")} - поиск по тэгу', + headers=current_app.config.get("SITE_HEADERS"), + menu_title=current_app.config.get("BRAND"), + menu_items=current_app.config.get("MENU_ITEMS"), + mylinks=current_app.config.get("MYLINKS"), + copyright=current_app.config.get("MYCOPYRIGHT"), ), 404, )