fix (rroles): Off by one error in maximum.
This commit is contained in:
@@ -272,7 +272,7 @@ class ReactionRoleMessage:
|
|||||||
# Fetch the number of applicable roles the user has
|
# Fetch the number of applicable roles the user has
|
||||||
roleids = set(reaction.data.roleid for reaction in self.reactions)
|
roleids = set(reaction.data.roleid for reaction in self.reactions)
|
||||||
member_roleids = set(role.id for role in member.roles)
|
member_roleids = set(role.id for role in member.roles)
|
||||||
if len(roleids.intersection(member_roleids)) > maximum:
|
if len(roleids.intersection(member_roleids)) >= maximum:
|
||||||
# Notify the user
|
# Notify the user
|
||||||
embed = discord.Embed(
|
embed = discord.Embed(
|
||||||
title="Maximum group roles reached!",
|
title="Maximum group roles reached!",
|
||||||
|
|||||||
Reference in New Issue
Block a user