mirror of
https://github.com/Hessenuk/DiscordTickets.git
synced 2024-12-23 00:03:09 +02:00
minor stuff
you can't remove yourself anymore
This commit is contained in:
parent
97524f2c15
commit
7c5ba65b0e
@ -154,7 +154,7 @@ module.exports = {
|
|||||||
&&
|
&&
|
||||||
fs.existsSync(`user/transcripts/raw/entities/${ticket.get('channel')}.json`)
|
fs.existsSync(`user/transcripts/raw/entities/${ticket.get('channel')}.json`)
|
||||||
)
|
)
|
||||||
embed.addField('Web archive', `${await archive.export(Ticket, channel)}`);
|
embed.addField('Web archive', await archive.export(Ticket, channel));
|
||||||
|
|
||||||
|
|
||||||
if (embed.fields.length < 1)
|
if (embed.fields.length < 1)
|
||||||
|
@ -68,7 +68,7 @@ module.exports = {
|
|||||||
|
|
||||||
let member = guild.member(message.mentions.users.first() || guild.members.cache.get(args[0]));
|
let member = guild.member(message.mentions.users.first() || guild.members.cache.get(args[0]));
|
||||||
|
|
||||||
if(!member || member.id === guild.me.id)
|
if(!member || member.id === message.author.id || member.id === guild.me.id)
|
||||||
return message.channel.send(
|
return message.channel.send(
|
||||||
new MessageEmbed()
|
new MessageEmbed()
|
||||||
.setColor(config.err_colour)
|
.setColor(config.err_colour)
|
||||||
|
@ -153,6 +153,7 @@ module.exports.export = (Ticket, channel) => new Promise((resolve, reject) => {
|
|||||||
|
|
||||||
resolve(res.url);
|
resolve(res.url);
|
||||||
}).catch(e => {
|
}).catch(e => {
|
||||||
|
log.warn(e);
|
||||||
return resolve(e);
|
return resolve(e);
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
Loading…
Reference in New Issue
Block a user