diff options
| author | Unknown <jtsshieh@outlook.com> | 2018-02-24 21:25:23 -0500 |
|---|---|---|
| committer | Unknown <jtsshieh@outlook.com> | 2018-02-24 21:25:23 -0500 |
| commit | e12f2cbace0c67631afab45a0d34360eb6e73fe7 (patch) | |
| tree | 7df085bed4d1d531c45fbb7d2b84f1ea61d52c48 /commands | |
| parent | 45246cd3a31a42ce16639d75541ff665357c7a6e (diff) | |
| download | PokeBot-e12f2cbace0c67631afab45a0d34360eb6e73fe7.tar.gz PokeBot-e12f2cbace0c67631afab45a0d34360eb6e73fe7.tar.bz2 PokeBot-e12f2cbace0c67631afab45a0d34360eb6e73fe7.zip | |
try this
Diffstat (limited to 'commands')
| -rw-r--r-- | commands/Pokemon/claim.js | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/commands/Pokemon/claim.js b/commands/Pokemon/claim.js index aa11ed1..e0d034e 100644 --- a/commands/Pokemon/claim.js +++ b/commands/Pokemon/claim.js @@ -2,11 +2,11 @@ exports.run = async (bot, msg) => { if (!msg.channel.topic.startsWith('Current Owner:')) return msg.reply('Go into one of the gym channels and try again.'); if (msg.channel.topic == 'Current Owner: *none*') { msg.reply('Alright, you have claimed this gym as yours! Be ready to battle anyone who approaches you'); - msg.channel.setTopic('Current Owner: ' + msg.author.id + '/' + msg.author.tag); + msg.channel.setTopic('Current Owner: ' + msg.author.tag + '/' + msg.author.id); } else { - const owner = msg.channel.topic.slice(15).substring(0, msg.author.id.length); - msg.channel.send('<@' + owner + '>, come here as ' + msg.author + ' wants to battle you.'); + const owner = msg.channel.topic.slice(15).substring(msg.author.tag.length); + msg.channel.send('<@' + owner + '>, come here as ' + msg.author.displayName + ' wants to battle you.'); } }; |
