d.py 2.3 / pomelo changes (#6130)

Co-authored-by: Michael Oliveira <34169552+Flame442@users.noreply.github.com>
This commit is contained in:
Jakub Kuczys
2023-06-14 04:56:50 +02:00
committed by GitHub
parent 3abf4cac05
commit 10e09d6abc
20 changed files with 216 additions and 173 deletions

View File

@@ -272,7 +272,9 @@ class Admin(commands.Cog):
`[p]editrole colour Test #ff9900`
"""
author = ctx.author
reason = "{}({}) changed the colour of role '{}'".format(author.name, author.id, role.name)
reason = _("{author} ({author.id}) changed the colour of role '{role.name}'").format(
author=author, role=role.name
)
if not self.pass_user_hierarchy_check(ctx, role):
await ctx.send(_(ROLE_USER_HIERARCHY_ISSUE).format(role=role))
@@ -303,9 +305,9 @@ class Admin(commands.Cog):
"""
author = ctx.message.author
old_name = role.name
reason = "{}({}) changed the name of role '{}' to '{}'".format(
author.name, author.id, old_name, name
)
reason = _(
"{author} ({author.id}) changed the name of role '{old_name}' to '{name}'"
).format(author=author, old_name=old_name, name=name)
if not self.pass_user_hierarchy_check(ctx, role):
await ctx.send(_(ROLE_USER_HIERARCHY_ISSUE).format(role=role))