[deviantart] fix arguments for search/popular results (#1408)

This commit is contained in:
Mike Fährmann
2021-03-25 22:51:12 +01:00
parent 522d0a834c
commit 214ecf62ce

View File

@@ -708,15 +708,16 @@ class DeviantartPopularExtractor(DeviantartExtractor):
if path:
self.category_path = path.strip("/")
if trange:
trange = trange[8:] if trange.startswith("popular-") else ""
if trange.startswith("popular-"):
trange = trange[8:]
self.time_range = trange.replace("-", "").replace("hours", "hr")
if query:
self.search_term = query.get("q")
self.popular = {
"search": self.search_term or "",
"range": trange or "24-hours",
"path": self.category_path,
"range" : trange or "",
"path" : self.category_path,
}
def deviations(self):