Re-add lyric search history storage, missed previously

This commit is contained in:
codey 2024-08-17 05:58:01 -04:00
parent 2855772ac1
commit ed3e9bd03a

View File

@ -95,7 +95,7 @@ class LyricSearch(FastAPI):
"IRC-KALI", "IRC-KALI",
"DISC-ACES", "DISC-ACES",
"DISC-HAVOC", "DISC-HAVOC",
"LIMNORIA-SHARED" "IRC-SHARED"
] ]
for endpoint, handler in self.endpoints.items(): for endpoint, handler in self.endpoints.items():
@ -183,6 +183,12 @@ class LyricSearch(FastAPI):
'errorText': 'Sources exhausted, lyrics not located.' 'errorText': 'Sources exhausted, lyrics not located.'
} }
await self.lyrics_engine.storeHistEntry(artist=search_worker.get('artist'),
song=search_worker.get('song'),
retr_method=search_worker.get('method'),
request_src=src.strip())
return { return {
'err': False, 'err': False,
'artist': search_worker['artist'], 'artist': search_worker['artist'],