[bellazon] improve 'filename' & 'extension' (#8544)

https://github.com/mikf/gallery-dl/issues/8544#issuecomment-3522617104

- use 'extension' from file URL (except attachments)
- strip everything after the first '.' from non-URL filenames
This commit is contained in:
Mike Fährmann
2025-11-12 18:38:44 +01:00
parent da47214ca0
commit d7e1351987
2 changed files with 19 additions and 4 deletions

View File

@@ -237,6 +237,17 @@ __tests__ = (
"id" : "14418097",
},
{
"#url" : "https://www.bellazon.com/main/topic/4322-candids/page/1066/#comment-3956772",
"#comment" : "weird/wrong 'filename' & 'extension' (#8544)",
"#class" : bellazon.BellazonPostExtractor,
"#count" : 16,
"extension" : "jpg",
"filename" : r"re:^[^.]+$",
"id" : r"re:^\d+$",
},
{
"#url" : "https://www.bellazon.com/main/topic/57872-millie-brady/",
"#class" : bellazon.BellazonThreadExtractor,