mirror of
https://github.com/maxdorninger/MediaManager.git
synced 2026-04-23 17:28:42 +02:00
ruff: enable A lint
This commit is contained in:
@@ -12,11 +12,11 @@ def get_year_from_date(first_air_date: str | None) -> int | None:
|
||||
return None
|
||||
|
||||
|
||||
def download_poster_image(storage_path: Path, poster_url: str, id: UUID) -> bool:
|
||||
def download_poster_image(storage_path: Path, poster_url: str, uuid: UUID) -> bool:
|
||||
res = requests.get(poster_url, stream=True, timeout=60)
|
||||
|
||||
if res.status_code == 200:
|
||||
image_file_path = storage_path.joinpath(str(id)).with_suffix("jpg")
|
||||
image_file_path = storage_path.joinpath(str(uuid)).with_suffix("jpg")
|
||||
image_file_path.write_bytes(res.content)
|
||||
|
||||
original_image = Image.open(image_file_path)
|
||||
|
||||
Reference in New Issue
Block a user