|
@@ -36,9 +36,13 @@ bot.markov = markov
|
|
|
|
|
|
@bot.on(InlineQuery)
|
|
|
async def on_inline_query(event):
|
|
|
- await event.answer([
|
|
|
- event.builder.article("Результат.", await run(event.text)),
|
|
|
- ])
|
|
|
+ text = event.text.strip()
|
|
|
+ if not text:
|
|
|
+ return
|
|
|
+
|
|
|
+ await event.answer([
|
|
|
+ event.builder.article("Результат.", text=await run(text)),
|
|
|
+ ])
|
|
|
|
|
|
|
|
|
@bot.on(NewMessage)
|