diff options
Diffstat (limited to 'gallery_dl/extractor/mastodon.py')
| -rw-r--r-- | gallery_dl/extractor/mastodon.py | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/gallery_dl/extractor/mastodon.py b/gallery_dl/extractor/mastodon.py index 493a8ef..9ce5772 100644 --- a/gallery_dl/extractor/mastodon.py +++ b/gallery_dl/extractor/mastodon.py @@ -31,6 +31,8 @@ class MastodonExtractor(BaseExtractor): def items(self): for status in self.statuses(): + if self._check_move: + self._check_move(status["account"]) if not self.reblogs and status["reblog"]: self.log.debug("Skipping %s (reblog)", status["id"]) continue @@ -56,6 +58,12 @@ class MastodonExtractor(BaseExtractor): """Return an iterable containing all relevant Status objects""" return () + def _check_move(self, account): + self._check_move = None + if "moved" in account: + self.log.warning("Account '%s' moved to '%s'", + account["acct"], account["moved"]["acct"]) + INSTANCES = { "mastodon.social": { @@ -192,6 +200,7 @@ class MastodonAPI(): handle = "@{}@{}".format(username, self.extractor.instance) for account in self.account_search(handle, 1): if account["username"] == username: + self.extractor._check_move(account) return account["id"] raise exception.NotFoundError("account") |
