added handling for new usernames
This commit is contained in:
parent
bb49e42391
commit
ce0dcdb2c9
1 changed files with 6 additions and 3 deletions
|
@ -482,8 +482,11 @@ class Info(commands.Cog):
|
|||
)
|
||||
data.set_footer(text=_("Member #{} | User ID: {}").format(member_number, member.id))
|
||||
|
||||
name = str(member)
|
||||
name = " ~ ".join((name, member.nick)) if member.nick else name
|
||||
if member.discriminator == "0":
|
||||
name = str(member.name)
|
||||
else:
|
||||
name = str(member)
|
||||
name = " - ".join((name, member.nick)) if member.nick else name
|
||||
name = filter_invites(name)
|
||||
|
||||
avatar = member.avatar_url_as(format='png')
|
||||
|
@ -509,4 +512,4 @@ class Info(commands.Cog):
|
|||
embed = discord.Embed(title=f"{role.name}", color=colorint, description=f"**ID:** {role.id}\n**Mention:** {role.mention}\n**Creation Date:** <t:{timestamp}>\n**Color:** [#{color}]({colorcodelink})\n**Hoisted:** {role.hoist}\n**Position:** {role.position}\n**Managed:** {role.managed}\n**Mentionable:** {role.mentionable}\n**Administrator:** {permissions.administrator}")
|
||||
if permissions.administrator == False and list_permissions == True:
|
||||
embed.add_field(name="Permissions", value=f"**Manage Server:** {permissions.manage_guild}\n**Manage Webhooks:** {permissions.manage_webhooks}\n**Manage Channels:** {permissions.manage_channels}\n**Manage Roles:** {permissions.manage_roles}\n**Manage Emojis:** {permissions.manage_emojis}\n**Manage Messages:** {permissions.manage_messages}\n**Manage Nicknames:** {permissions.manage_nicknames}\n**Mention @everyone**: {permissions.mention_everyone}\n**Ban Members:** {permissions.ban_members}\n**Kick Members:** {permissions.kick_members}")
|
||||
await ctx.send(embed=embed)
|
||||
await ctx.send(embed=embed)
|
||||
|
|
Loading…
Reference in a new issue