Actually show where the messages are being forwarded to in .toggleimages
This commit is contained in:
parent
e8a092a7a9
commit
92b14f21f9
8
main.js
8
main.js
|
@ -67,11 +67,11 @@ client.on('messageCreate', async message => {
|
||||||
if (args.length === 1) {
|
if (args.length === 1) {
|
||||||
let response = "Image forwarding status for channels:\n";
|
let response = "Image forwarding status for channels:\n";
|
||||||
Object.keys(channelMappings).forEach(sourceChannelId => {
|
Object.keys(channelMappings).forEach(sourceChannelId => {
|
||||||
if (sourceChannelId === 'undefined' || !sourceChannelId) {
|
if (!sourceChannelId || sourceChannelId === 'undefined') return;
|
||||||
return;
|
|
||||||
}
|
const targetChannelId = channelMappings[sourceChannelId];
|
||||||
const status = channelSettings.includeImages[sourceChannelId] ? "Enabled" : "Disabled";
|
const status = channelSettings.includeImages[sourceChannelId] ? "Enabled" : "Disabled";
|
||||||
response += `- <#${sourceChannelId}> - (${sourceChannelId}): ${status}\n`;
|
response += `- <#${sourceChannelId}> to <#${targetChannelId}>: ${status}\n`;
|
||||||
});
|
});
|
||||||
return message.channel.send(response).then(msg => setTimeout(() => msg.delete(), 10000));
|
return message.channel.send(response).then(msg => setTimeout(() => msg.delete(), 10000));
|
||||||
} else if (args.length === 2) {
|
} else if (args.length === 2) {
|
||||||
|
|
Loading…
Reference in New Issue