aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGravatar ks129 <[email protected]>2021-04-01 18:57:26 +0300
committerGravatar GitHub <[email protected]>2021-04-01 18:57:26 +0300
commitc94fdb0fa5db711236ea02b5bb269e5db906c1a8 (patch)
tree2bd5b2770a2cc3fca0823b5243a28ef3fe097364
parentMerge pull request #1492 from python-discord/fix-delete-closing-reason-stat (diff)
parentMerge branch 'main' into allow-poll-to-leads (diff)
Merge pull request #1464 from python-discord/allow-poll-to-leads
Allow !poll to leads
-rw-r--r--bot/constants.py2
-rw-r--r--bot/exts/utils/utils.py4
-rw-r--r--config-default.yml2
3 files changed, 6 insertions, 2 deletions
diff --git a/bot/constants.py b/bot/constants.py
index bcf246e72..8c42daca6 100644
--- a/bot/constants.py
+++ b/bot/constants.py
@@ -486,9 +486,11 @@ class Roles(metaclass=YAMLGetter):
admins: int
core_developers: int
devops: int
+ domain_leads: int
helpers: int
moderators: int
owners: int
+ project_leads: int
jammers: int
team_leaders: int
diff --git a/bot/exts/utils/utils.py b/bot/exts/utils/utils.py
index a5d6f69b9..cae7f2593 100644
--- a/bot/exts/utils/utils.py
+++ b/bot/exts/utils/utils.py
@@ -9,7 +9,7 @@ from discord.ext.commands import BadArgument, Cog, Context, clean_content, comma
from discord.utils import snowflake_time
from bot.bot import Bot
-from bot.constants import Channels, MODERATION_ROLES, STAFF_ROLES
+from bot.constants import Channels, MODERATION_ROLES, Roles, STAFF_ROLES
from bot.converters import Snowflake
from bot.decorators import in_whitelist
from bot.pagination import LinePaginator
@@ -175,7 +175,7 @@ class Utils(Cog):
await ctx.send(embed=embed)
@command(aliases=("poll",))
- @has_any_role(*MODERATION_ROLES)
+ @has_any_role(*MODERATION_ROLES, Roles.project_leads, Roles.domain_leads)
async def vote(self, ctx: Context, title: clean_content(fix_channel_mentions=True), *options: str) -> None:
"""
Build a quick voting poll with matching reactions with the provided options.
diff --git a/config-default.yml b/config-default.yml
index 1b5ef42fe..6dec75fdc 100644
--- a/config-default.yml
+++ b/config-default.yml
@@ -263,9 +263,11 @@ guild:
admins: &ADMINS_ROLE 267628507062992896
core_developers: 587606783669829632
devops: 409416496733880320
+ domain_leads: 807415650778742785
helpers: &HELPERS_ROLE 267630620367257601
moderators: &MODS_ROLE 267629731250176001
owners: &OWNERS_ROLE 267627879762755584
+ project_leads: 815701647526330398
# Code Jam
jammers: 737249140966162473