Refactor code structure for improved readability and maintainability
This commit is contained in:
BIN
dist/renamer-0.5.4-py3-none-any.whl
vendored
Normal file
BIN
dist/renamer-0.5.4-py3-none-any.whl
vendored
Normal file
Binary file not shown.
@@ -1,6 +1,6 @@
|
|||||||
[project]
|
[project]
|
||||||
name = "renamer"
|
name = "renamer"
|
||||||
version = "0.5.3"
|
version = "0.5.4"
|
||||||
description = "Terminal-based media file renamer and metadata viewer"
|
description = "Terminal-based media file renamer and metadata viewer"
|
||||||
readme = "README.md"
|
readme = "README.md"
|
||||||
requires-python = ">=3.11"
|
requires-python = ">=3.11"
|
||||||
|
|||||||
@@ -206,6 +206,13 @@ class TMDBExtractor:
|
|||||||
return str(movie_info['runtime'])
|
return str(movie_info['runtime'])
|
||||||
return None
|
return None
|
||||||
|
|
||||||
|
def extract_movie_db(self) -> Optional[Tuple[str, str]]:
|
||||||
|
"""Extract TMDB database info as (name, id) tuple"""
|
||||||
|
movie_id = self.extract_tmdb_id()
|
||||||
|
if movie_id:
|
||||||
|
return ("tmdb", movie_id)
|
||||||
|
return None
|
||||||
|
|
||||||
def extract_popularity(self) -> Optional[str]:
|
def extract_popularity(self) -> Optional[str]:
|
||||||
"""Extract TMDB popularity"""
|
"""Extract TMDB popularity"""
|
||||||
movie_info = self._get_movie_info()
|
movie_info = self._get_movie_info()
|
||||||
|
|||||||
Reference in New Issue
Block a user