Skip to content

Commit

Permalink
Fix Update Notification #2
Browse files Browse the repository at this point in the history
🐛 When getting an update notification the new available version was displayed wrong
🔖 Bumped version to 2.1.1
🔖 Bumped tools version to 2.0.1
  • Loading branch information
AstroGD committed Nov 26, 2020
1 parent 6acacdc commit ada7fa8
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions modules/discord-accept-rules-bot.js
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ module.exports = function (client, fs, tools, dir) {
this.activated = true;
}

if (tools.isVersionLower(VERSIONINFO.packages.acceptRulesBot, version)) tools.log(scriptName, `Theres a new version available for Discord Accept Rules Module (${version} --> ${VERSIONINFO.version})`, 2);
if (tools.isVersionLower(VERSIONINFO.packages.acceptRulesBot, version)) tools.log(scriptName, `Theres a new version available for Discord Accept Rules Module (${version} --> ${VERSIONINFO.packages.acceptRulesBot})`, 2);

this.db = JSON.parse(fs.readFileSync(`${dir}/db/discord-accept-rules-bot.db`, "utf-8"));
this.config = checkConfigVersion(require(`${dir}/config/discord-accept-rules-bot.json`));
Expand Down Expand Up @@ -277,7 +277,7 @@ module.exports = function (client, fs, tools, dir) {

function checkVersion() {
if (tools.isVersionLower(VERSIONINFO.packages.acceptRulesBot, version)) {
tools.log(scriptName, `Theres a new version available for Discord Accept Rules Module (${version} --> ${VERSIONINFO.version})`, 2);
tools.log(scriptName, `Theres a new version available for Discord Accept Rules Module (${version} --> ${VERSIONINFO.packages.acceptRulesBot})`, 2);
return true;
}

Expand Down
2 changes: 1 addition & 1 deletion tools/tools.js
Original file line number Diff line number Diff line change
Expand Up @@ -205,7 +205,7 @@ module.exports = function (Discord, client, fs, dir, mainframeversion) {

function checkToolsVersion() {
if (isVersionLower(VERSIONINFO.packages.tools, version)) {
tools.log(scriptName, `Theres a new version available for Mainframe Tools (${version} --> ${VERSIONINFO.version})`, 2);
tools.log(scriptName, `Theres a new version available for Mainframe Tools (${version} --> ${VERSIONINFO.packages.tools})`, 2);
return true;
}

Expand Down

0 comments on commit ada7fa8

Please sign in to comment.