Skip to content

Commit

Permalink
Revert "[Deviantart] [#1776] Remove the "you need session cookies to …
Browse files Browse the repository at this point in the history
…download mature scraps" warning (#1777)"

This reverts commit 1f02878.

Mature scraps do yet again require cookies.
  • Loading branch information
mikf committed Nov 1, 2022
1 parent 460095a commit 2a1cb40
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions gallery_dl/extractor/deviantart.py
Original file line number Diff line number Diff line change
Expand Up @@ -960,9 +960,15 @@ class DeviantartScrapsExtractor(DeviantartExtractor):
)
cookiedomain = ".deviantart.com"
cookienames = ("auth", "auth_secure", "userinfo")
_warning = True

def deviations(self):
eclipse_api = DeviantartEclipseAPI(self)
if self._warning:
DeviantartScrapsExtractor._warning = False
if not self._check_cookies(self.cookienames):
self.log.warning(
"No session cookies set: Unable to fetch mature scraps.")

for obj in eclipse_api.gallery_scraps(self.user, self.offset):
deviation = obj["deviation"]
Expand Down

0 comments on commit 2a1cb40

Please sign in to comment.