minor code cleanup
This commit is contained in:
parent
0d2fd4b9d2
commit
4f42e0afad
@ -337,6 +337,7 @@ class ComicFilenameParser:
|
||||
self._path_indexes: dict[str, int] = {}
|
||||
|
||||
|
||||
def comicfn2dict(path: str | Path):
|
||||
def comicfn2dict(path: str | Path, verbose: int = 0):
|
||||
"""Simple API."""
|
||||
return ComicFilenameParser(path).parse()
|
||||
parser = ComicFilenameParser(path, verbose=verbose)
|
||||
return parser.parse()
|
||||
|
@ -112,6 +112,7 @@ class ComicFilenameSerializer:
|
||||
self._debug: bool = bool(verbose)
|
||||
|
||||
|
||||
def dict2comicfn(md: Mapping, ext: bool = True) -> str:
|
||||
def dict2comicfn(md: Mapping, ext: bool = True, verbose: int = 0) -> str:
|
||||
"""Simple API."""
|
||||
return ComicFilenameSerializer(md, ext=ext).serialize()
|
||||
serializer = ComicFilenameSerializer(md, ext=ext, verbose=verbose)
|
||||
return serializer.serialize()
|
||||
|
Loading…
Reference in New Issue
Block a user