mirror of
https://github.com/saveweb/biliarchiver.git
synced 2024-09-19 11:05:28 -07:00
chore: remove temp txt file after reading
This commit is contained in:
parent
aa93f7104c
commit
e3757b1aa0
@ -26,4 +26,5 @@ def read_bvids(bvids: str) -> list[str]:
|
||||
def read_bvids_from_txt(txt_path: Union[Path,str]) -> List[str]:
|
||||
with open(txt_path, "r", encoding="utf-8") as f:
|
||||
bvids = [line.strip() for line in f if line.strip().startswith("BV")]
|
||||
txt_path.unlink(missing_ok=True)
|
||||
return bvids
|
Loading…
Reference in New Issue
Block a user