Advertisement
Guest User

Untitled

a guest
Feb 24th, 2018
75
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.82 KB | None | 0 0
  1. @client.command(pass_context=True)
  2. async def add(ctx):
  3. #check to see if role exists
  4. roleExist = None
  5. for x in ctx.message.server.roles:
  6. if str(x) == "Follower":
  7. roleExist = True
  8. await client.say("Role: Follower already exists.")
  9. if roleExist == None:
  10. await client.say("Role does not exist, creating a new one now")
  11. await client.create_role(ctx.message.server, name="Follower", colour=discord.Colour.gold(), hoist=True, mentionable=True)
  12. else:
  13. pass
  14. #assigns role
  15. #await client.say("Assining roles now")
  16. role = discord.utils.get(ctx.message.server.roles, name="Follower")
  17. await client.add_roles(ctx.message.author, role)
  18.  
  19.  
  20. """
  21. The bug appears when i comment out await clien.say("Assining roles now") but not when i leave it in
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement