From 255e52bf452e9b8ab4f6c14a2725de7c9ae2867c Mon Sep 17 00:00:00 2001 From: Fabio De Simone Date: Mon, 28 Jan 2019 22:51:10 +0100 Subject: [PATCH] fixed idiotic bug --- telegrambot.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/telegrambot.py b/telegrambot.py index 07a0be96..0d377316 100644 --- a/telegrambot.py +++ b/telegrambot.py @@ -298,7 +298,7 @@ def cmd_search(bot: Bot, update: Update): text = update.message.text.split(" ", 1)[1] if text is None: return - text = text.replace('%','\\%').replace('_','\_') + text = text.replace('%','\\%').replace('_','\_') entries = session.query(db.Diario).filter(db.Diario.text.ilike('%'+text+'%')).all() messageText = "Ecco i risulati della ricerca:\n" for entry in entries[:5]: