mirror of
https://github.com/nathom/streamrip.git
synced 2025-05-13 14:44:49 -04:00
parent
81751cc2a1
commit
2fd59ac1ef
2 changed files with 5 additions and 2 deletions
|
@ -86,6 +86,9 @@ class Config:
|
|||
os.makedirs(CONFIG_DIR, exist_ok=True)
|
||||
|
||||
shutil.copy(self.default_config_path, self._path)
|
||||
self.load()
|
||||
self.file["downloads"]["folder"] = DOWNLOADS_DIR
|
||||
self.save()
|
||||
|
||||
def load(self):
|
||||
"""Load infomation from the config files, making a deepcopy."""
|
||||
|
|
|
@ -107,7 +107,7 @@ class Track:
|
|||
logger.debug("Cover url: %s", u)
|
||||
self.cover_url = u
|
||||
|
||||
def load_meta(self):
|
||||
def load_meta(self, **kwargs):
|
||||
"""Send a request to the client to get metadata for this Track.
|
||||
|
||||
Usually only called for single tracks and last.fm playlists.
|
||||
|
@ -672,7 +672,7 @@ class Video:
|
|||
self.explicit = kwargs.get("explicit", False)
|
||||
self.tracknumber = kwargs.get("tracknumber", None)
|
||||
|
||||
def load_meta(self):
|
||||
def load_meta(self, **kwargs):
|
||||
"""Given an id at contruction, get the metadata of the video."""
|
||||
resp = self.client.get(self.id, "video")
|
||||
self.title = resp["title"]
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue