Skip to content

Commit

Permalink
search string escaped
Browse files Browse the repository at this point in the history
  • Loading branch information
ponlponl123 committed Mar 10, 2025
1 parent 293bc2b commit 211ac39
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions src/routers/search.py
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
from typing import Any
from fastapi import APIRouter, HTTPException
from fastapi import APIRouter, HTTPException, Query
from ytmusicapi import YTMusic

router = APIRouter()

@router.get("/search/{query}")
@router.get("/search")
async def search(
query: str,
query: str = Query(..., description="Search query"),
filter: str | None = None,
ignore_spelling: bool = False,
limit: int = 20,
Expand All @@ -30,9 +30,9 @@ async def search(
"result": search_results
}

@router.get("/search_suggestions/{query}")
@router.get("/search_suggestions")
async def get_search_suggestions(
query: str,
query: str = Query(..., description="Search query"),
detailed_runs: bool = False
):
ytmusic = YTMusic()
Expand Down

0 comments on commit 211ac39

Please sign in to comment.