Compare commits
2 commits
5dc81a4508
...
27329865ee
Author | SHA1 | Date | |
---|---|---|---|
27329865ee | |||
0ae7d01a1e |
2 changed files with 5 additions and 7 deletions
|
@ -139,11 +139,9 @@ def wipe(path: Path) -> None:
|
||||||
:type path: Path
|
:type path: Path
|
||||||
"""
|
"""
|
||||||
try:
|
try:
|
||||||
shutil.rmtree(path)
|
|
||||||
except NotADirectoryError:
|
|
||||||
path.unlink(missing_ok=True)
|
path.unlink(missing_ok=True)
|
||||||
except FileNotFoundError:
|
except IsADirectoryError:
|
||||||
pass
|
shutil.rmtree(path)
|
||||||
|
|
||||||
|
|
||||||
def write(file_path: Path, text: str, charset: str = CHARSET) -> None:
|
def write(file_path: Path, text: str, charset: str = CHARSET) -> None:
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
"""FreeTube artists."""
|
"""FreeTube authors."""
|
||||||
|
|
||||||
from typing import TYPE_CHECKING
|
from typing import TYPE_CHECKING
|
||||||
|
|
||||||
|
@ -8,8 +8,8 @@ if TYPE_CHECKING:
|
||||||
from .playlists import Playlist
|
from .playlists import Playlist
|
||||||
|
|
||||||
|
|
||||||
class Artist(Object):
|
class Author(Object):
|
||||||
"""FreeTube artist."""
|
"""FreeTube author."""
|
||||||
|
|
||||||
def __init__(self, uid: str, name: str) -> None:
|
def __init__(self, uid: str, name: str) -> None:
|
||||||
"""Set uid & name.
|
"""Set uid & name.
|
Loading…
Reference in a new issue