Skip to content

Commit

Permalink
✨ Add Guild.activity_feed_enabled to know whether the activity feed…
Browse files Browse the repository at this point in the history
… is enabled for the guild.
  • Loading branch information
Paillat-dev committed Dec 17, 2024
1 parent 9bb2a57 commit 58d5beb
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions discord/guild.py
Original file line number Diff line number Diff line change
Expand Up @@ -676,6 +676,11 @@ def categories(self) -> list[CategoryChannel]:
r.sort(key=lambda c: (c.position or -1, c.id))
return r

@property
def activity_feed_enabled(self) -> bool:
"""Returns ``True`` if the guild has the activity feed enabled."""
return "ACTIVITY_FEED_DISABLED_BY_USER" not in self.features

def by_category(self) -> list[ByCategoryItem]:
"""Returns every :class:`CategoryChannel` and their associated channels.
Expand Down

0 comments on commit 58d5beb

Please sign in to comment.