feat: restore ability to open website from an inline query message
Signed-off-by: mctaylors <cantsendmails@mctaylors.ru>
This commit is contained in:
parent
c1f803503e
commit
c66b52a29b
1 changed files with 11 additions and 3 deletions
|
@ -13,6 +13,7 @@ from telegram.constants import ParseMode
|
|||
from telegram.ext import ContextTypes
|
||||
|
||||
import html_parser
|
||||
from config import app
|
||||
from extensions import humanize_tags_from_json, format_rating, get_json
|
||||
|
||||
|
||||
|
@ -102,9 +103,16 @@ async def answer_query(
|
|||
" ".join(
|
||||
[
|
||||
html_parser.code(f"#{query}"),
|
||||
html_parser.hyperlink(
|
||||
" ".join(
|
||||
[
|
||||
html_parser.bold(f"{characters} ({copyrights})"),
|
||||
"drawn by",
|
||||
html_parser.bold(artists),
|
||||
]
|
||||
),
|
||||
f"{app.protocol}://{app.hostname}/posts/{query}",
|
||||
),
|
||||
rating,
|
||||
]
|
||||
),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue