diff options
| author | 2024-12-02 00:31:59 -0500 | |
|---|---|---|
| committer | 2024-12-02 00:31:59 -0500 | |
| commit | 1981ccaaea6eab2cf32536ec5afe132a870914d8 (patch) | |
| tree | 013f1e17d922d3a6abf7f57aa6a175c2ce5d93bc /gallery_dl/extractor/lolisafe.py | |
| parent | fc004701f923bb954a22c7fec2ae8d607e78cb2b (diff) | |
New upstream version 1.28.0.upstream/1.28.0
Diffstat (limited to 'gallery_dl/extractor/lolisafe.py')
| -rw-r--r-- | gallery_dl/extractor/lolisafe.py | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/gallery_dl/extractor/lolisafe.py b/gallery_dl/extractor/lolisafe.py index 044f4f5..295b9c4 100644 --- a/gallery_dl/extractor/lolisafe.py +++ b/gallery_dl/extractor/lolisafe.py @@ -46,12 +46,17 @@ class LolisafeAlbumExtractor(LolisafeExtractor): for data["num"], file in enumerate(files, 1): url = file["file"] file.update(data) - text.nameext_from_url(url, file) + + if "extension" not in file: + text.nameext_from_url(url, file) if "name" in file: name = file["name"] file["name"] = name.rpartition(".")[0] or name file["id"] = file["filename"].rpartition("-")[2] + elif "id" in file: + file["name"] = file["filename"] + file["filename"] = "{}-{}".format(file["name"], file["id"]) else: file["name"], sep, file["id"] = \ file["filename"].rpartition("-") |
