diff --git a/app.py b/app.py
index 5825a4d..2bb73bc 100644
--- a/app.py
+++ b/app.py
@@ -60,7 +60,8 @@ def colorify(model):
@app.route('/')
def home():
- return render_template('layout.html', search_form=SearchForm(), title='Animes torrents search engine')
+ return render_template('layout.html', search_form=SearchForm(), title='Animes torrents search engine',
+ mysql_disabled=not MYSQL_ENABLED)
@app.route('/search')
diff --git a/templates/layout.html b/templates/layout.html
index babe390..21d5de0 100644
--- a/templates/layout.html
+++ b/templates/layout.html
@@ -23,7 +23,7 @@
Latest torrents
- {% if mysql_disabled %}
+ {% if not mysql_disabled %}