Add changing preview type when searching track

This commit is contained in:
BarsTiger committed 2023-11-07 18:45:41 +02:00
1 parent 06c327933f
commit e99ba9daa3
12 files changed
+54 -23

No files matched your search

+3 -1
View File
@@ -3,13 +3,14 @@ from aiogram.types import (
)
from bot.modules.url import recognise_music_service, get_id
from bot.modules.settings import UserSettings
from ..common.search import get_common_search_result
import inspect
async def get_url_results(query: str) -> list[
async def get_url_results(query: str, settings: UserSettings) -> list[
InlineQueryResultDocument | InlineQueryResultCachedAudio
]:
service = recognise_music_service(query)
@@ -25,5 +26,6 @@ async def get_url_results(query: str) -> list[
audio=audio,
db_table=service.db_table,
service_id=service.name,
settings=settings
)
]