Skip to content

Commit

Permalink
Remove MemberRole on addding.
Browse files Browse the repository at this point in the history
  • Loading branch information
shubham399 committed Oct 20, 2019
1 parent 1963cb1 commit f1484b9
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion commands/non-htb-verify.js
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,11 @@ const getUserData = (token) => {

const giveRole = function(member, author, channel, hasRole, defaultRole) {
if (!hasRole) {
let deadRole = member.roles.find(r => r.name === "DeadAccount")
let memberRole = member.roles.find(r => r.name === "Member");
if (memberRole) {
await (member.removeRole(memberRole.id))
}
let deadRole = member.roles.find(r => r.name === "DeadAccount");
if (deadRole) {
await (member.removeRole(deadRole.id))
}
Expand Down

0 comments on commit f1484b9

Please sign in to comment.