mirror of
https://github.com/maxdorninger/MediaManager.git
synced 2026-04-19 17:54:12 +02:00
format files
This commit is contained in:
@@ -6,6 +6,7 @@ import pillow_avif
|
||||
|
||||
pillow_avif
|
||||
|
||||
|
||||
def get_year_from_date(first_air_date: str | None) -> int | None:
|
||||
if first_air_date:
|
||||
return int(first_air_date.split("-")[0])
|
||||
@@ -13,7 +14,7 @@ def get_year_from_date(first_air_date: str | None) -> int | None:
|
||||
return None
|
||||
|
||||
|
||||
def download_poster_image(storage_path=None, poster_url=None, id: UUID=None) -> bool:
|
||||
def download_poster_image(storage_path=None, poster_url=None, id: UUID = None) -> bool:
|
||||
res = requests.get(poster_url, stream=True)
|
||||
if res.status_code == 200:
|
||||
image_file_path = storage_path.joinpath(str(id))
|
||||
|
||||
Reference in New Issue
Block a user