mirror of
https://github.com/Dvorinka/swingmusic-extended.git
synced 2026-10-29 10:54:42 +00:00
fix: folder endpoint returning same track for different files of the same trackhash
+ fix: chunked streaming. return instead of yield chunks
This commit is contained in:
1 parent
cd992419c5
commit
ca31054f48
18 files changed
+508
-138
No files matched your search
+2
-2
@@ -1,5 +1,5 @@
|
||||
import datetime
|
||||
from typing import Any
|
||||
from typing import Any, Literal
|
||||
from sqlalchemy import (
|
||||
JSON,
|
||||
Boolean,
|
||||
@@ -409,7 +409,7 @@ class LibDataTable(Base):
|
||||
)
|
||||
|
||||
@classmethod
|
||||
def find_one(cls, hash: str, type: str):
|
||||
def find_one(cls, hash: str, type: Literal["album", "artist"]):
|
||||
result = cls.execute(
|
||||
select(cls).where((cls.itemhash == hash) & (cls.itemtype == type))
|
||||
)
|
||||
|
||||
Reference in new issue
Block a user