Merge branch 'master' of github.com:Dragory/modmailbot
commit
d5f8839446
|
@ -5,3 +5,4 @@
|
||||||
!/config.example.ini
|
!/config.example.ini
|
||||||
/welcome.png
|
/welcome.png
|
||||||
/update.sh
|
/update.sh
|
||||||
|
/tags.*
|
||||||
|
|
|
@ -50,6 +50,7 @@ module.exports = {
|
||||||
'okey thx',
|
'okey thx',
|
||||||
'okey no problem',
|
'okey no problem',
|
||||||
'okey np',
|
'okey np',
|
||||||
'cheers'
|
'cheers',
|
||||||
|
'!close'
|
||||||
],
|
],
|
||||||
};
|
};
|
||||||
|
|
|
@ -124,6 +124,7 @@ function initBaseMessageHandlers() {
|
||||||
messageQueue.add(async () => {
|
messageQueue.add(async () => {
|
||||||
let thread = await threads.findOpenThreadByUserId(msg.author.id);
|
let thread = await threads.findOpenThreadByUserId(msg.author.id);
|
||||||
|
|
||||||
|
|
||||||
// New thread
|
// New thread
|
||||||
if (! thread) {
|
if (! thread) {
|
||||||
// Ignore messages that shouldn't usually open new threads, such as "ok", "thanks", etc.
|
// Ignore messages that shouldn't usually open new threads, such as "ok", "thanks", etc.
|
||||||
|
@ -211,11 +212,12 @@ function initBaseMessageHandlers() {
|
||||||
const staffMention = (config.pingOnBotMention ? utils.getInboxMention() : '');
|
const staffMention = (config.pingOnBotMention ? utils.getInboxMention() : '');
|
||||||
|
|
||||||
if (mainGuilds.length === 1) {
|
if (mainGuilds.length === 1) {
|
||||||
content = `${staffMention}Bot mentioned in ${msg.channel.mention} by **${msg.author.username}#${msg.author.discriminator}**: "${msg.cleanContent}"`;
|
content = `${staffMention}Bot mentioned in ${msg.channel.mention} by **${msg.author.username}#${msg.author.discriminator}(${msg.author.id})**: "${msg.cleanContent}"\n\n<https:\/\/discordapp.com\/channels\/${msg.channel.guild.id}\/${msg.channel.id}\/${msg.id}>`;
|
||||||
} else {
|
} else {
|
||||||
content = `${staffMention}Bot mentioned in ${msg.channel.mention} (${msg.channel.guild.name}) by **${msg.author.username}#${msg.author.discriminator}**: "${msg.cleanContent}"`;
|
content = `${staffMention}Bot mentioned in ${msg.channel.mention} (${msg.channel.guild.name}) by **${msg.author.username}#${msg.author.discriminator}(${msg.author.id})**: "${msg.cleanContent}"\n\n<https:\/\/discordapp.com\/channels\/${msg.channel.guild.id}\/${msg.channel.id}\/${msg.id}>`;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
bot.createMessage(utils.getLogChannel().id, {
|
bot.createMessage(utils.getLogChannel().id, {
|
||||||
content,
|
content,
|
||||||
disableEveryone: false,
|
disableEveryone: false,
|
||||||
|
|
Loading…
Reference in New Issue