diff options
| author | 2018-07-25 22:35:27 +0200 | |
|---|---|---|
| committer | 2018-07-25 22:35:27 +0200 | |
| commit | ec486db76ab8962ad95e4f4b91d882eba0ac748d (patch) | |
| tree | 4ce3d41fc54c54abd6a81ca285c8ecc913cff770 | |
| parent | Updating config-default.yml with the required configuration parameters for th... (diff) | |
Adding all the constants to the dataclass.
| -rw-r--r-- | bot/constants.py | 74 | ||||
| -rw-r--r-- | config-default.yml | 8 | 
2 files changed, 46 insertions, 36 deletions
diff --git a/bot/constants.py b/bot/constants.py index 9c6e75c9b..3cb9849aa 100644 --- a/bot/constants.py +++ b/bot/constants.py @@ -191,6 +191,51 @@ class Bot(metaclass=YAMLGetter):      token: str +class Censor(metaclass=YAMLGetter): +    section = "censor" + +    filter_zalgo: bool +    filter_invites: bool +    filter_domain: bool +    filter_expression: bool + +    domain_blacklist: List[str] +    blocked_expressions: List[str] +    guild_invite_whitelist: List[str] + +    channel_whitelist: List[int] +    role_whitelist: List[int] + + +class Channels(metaclass=YAMLGetter): +    section = "guild" +    subsection = "channels" + +    admins: int +    announcements: int +    big_brother_logs: int +    bot: int +    checkpoint_test: int +    devalerts: int +    devlog: int +    devtest: int +    help_0: int +    help_1: int +    help_2: int +    help_3: int +    help_4: int +    help_5: int +    helpers: int +    message_log: int +    modlog: int +    off_topic_1: int +    off_topic_2: int +    off_topic_3: int +    python: int +    staff_lounge: int +    verification: int + +  class Cooldowns(metaclass=YAMLGetter):      section = "bot"      subsection = "cooldowns" @@ -236,35 +281,6 @@ class Icons(metaclass=YAMLGetter):      user_update: str -class Channels(metaclass=YAMLGetter): -    section = "guild" -    subsection = "channels" - -    admins: int -    announcements: int -    big_brother_logs: int -    bot: int -    checkpoint_test: int -    devalerts: int -    devlog: int -    devtest: int -    help_0: int -    help_1: int -    help_2: int -    help_3: int -    help_4: int -    help_5: int -    helpers: int -    message_log: int -    modlog: int -    off_topic_1: int -    off_topic_2: int -    off_topic_3: int -    python: int -    staff_lounge: int -    verification: int - -  class Roles(metaclass=YAMLGetter):      section = "guild"      subsection = "roles" diff --git a/config-default.yml b/config-default.yml index aed07c137..ce2600c61 100644 --- a/config-default.yml +++ b/config-default.yml @@ -38,11 +38,6 @@ bot:          user_update: "https://cdn.discordapp.com/emojis/469952898684551168.png" - - - - -  guild:      id: 267624335836053506 @@ -87,7 +82,6 @@ guild:  censor: -      # What do we filter?      filter_zalgo:      true      filter_invites:    true @@ -110,12 +104,12 @@ censor:      # Censor doesn't apply to these      channel_whitelist:          - *ADMINS -        - *DEVTEST          - *MODLOG          - *MESSAGE_LOG          - *DEVLOG          - *BBLOGS          - *STAFF_LOUNGE +#       - *DEVTEST      role_whitelist:          - *ADMIN_ROLE  |