Browse Source

Merged hotfix/developer-messages into master

shorten
benji7425 4 years ago
parent
commit
e2b07fc649
  1. 6
      CHANGELOG.md
  2. 18
      feed-bot.js
  3. 2
      package.json

6
CHANGELOG.md

@ -1,5 +1,11 @@
# Changelog
## v1.3.1
### Fixed
- Developer commands can now be used from any channel or PM
## v1.3.0
### Added

18
feed-bot.js

@ -61,15 +61,15 @@ var DiscordClient = {
return url;
});
}
else {
//iterate over all of our message triggers to see if the message sent requires any action
for (var i = 0; i < DiscordClient.messageTriggers.length; i++) {
var messageTrigger = DiscordClient.messageTriggers[i];
if (message === messageTrigger.message) {
//check if its locked to a channel or to a specific user
if ((messageTrigger.channelID && messageTrigger.channelID === channelID) || (messageTrigger.userIDs && messageTrigger.userIDs.includes(userID)))
messageTrigger.action(user, userID, channelID, message);
}
}
else {
//iterate over all of our message triggers to see if the message sent requires any action
for (var i = 0; i < DiscordClient.messageTriggers.length; i++) {
var messageTrigger = DiscordClient.messageTriggers[i];
if (message === messageTrigger.message) {
//check if its locked to a channel or to a specific user
if ((messageTrigger.channelID && messageTrigger.channelID === channelID) || (messageTrigger.userIDs && messageTrigger.userIDs.includes(userID)))
messageTrigger.action(user, userID, channelID, message);
}
}
}

2
package.json

@ -1,6 +1,6 @@
{
"name": "discord-feed-bot",
"version": "1.3.0",
"version": "1.3.1",
"description": "discord-feed-bot",
"main": "index.js",
"scripts": {

Loading…
Cancel
Save