1
0
mirror of https://github.com/Adam-Ant/QuotesDB synced 2024-12-20 11:34:35 +00:00

Use unescaped quote for telegram

This commit is contained in:
Adam Dodman 2017-10-20 21:38:35 +01:00
parent 14bdd69cdf
commit 0a72a7f283

View File

@ -243,7 +243,7 @@ def addquote():
if telegramEnabled:
try:
with urllib.request.urlopen('https://api.telegram.org/bot%s/sendmessage?parse_mode=Markdown&chat_id=%i&text=*%s just added a quote to the database:*%%0A %s - _%s_' % (telegramToken, telegramChatid, session['username'], quotein, utility_processor()['uid_to_user'](userin))) as urlreq:
with urllib.request.urlopen('https://api.telegram.org/bot%s/sendmessage?parse_mode=Markdown&chat_id=%i&text=*%s just added a quote to the database:*%%0A %s - _%s_' % (telegramToken, telegramChatid, session['username'], cleanup_string(request.form['quote']), utility_processor()['uid_to_user'](userin))) as urlreq:
urlreq.read()
except urllib.error.HTTPError:
print("Warning: Telegram notify error!")