Fix presence not setting correctly when <prefix>
This commit is contained in:
parent
f4467637b0
commit
1e91d4ddef
2 changed files with 5 additions and 4 deletions
|
@ -21,9 +21,8 @@ module.exports = {
|
|||
const firstArg = args[0].length + 1;
|
||||
let temp = args.join(" ");
|
||||
let regex = /<prefix>/g
|
||||
temp = temp.replace(regex, globalPrefix)
|
||||
let presenceText = temp.slice(firstArg, temp.length)
|
||||
client.user.setActivity(presenceText, { type: presenceType });
|
||||
client.user.setActivity(presenceText.replace(regex, globalPrefix), { type: presenceType });
|
||||
savePresence(presenceType, presenceText);
|
||||
message.channel.send("Updated presence.")
|
||||
}else return;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue