Skip to content

Commit

Permalink
version compare fix
Browse files Browse the repository at this point in the history
  • Loading branch information
Alorel committed Feb 25, 2017
1 parent 4e80c8b commit 6f6f5f2
Show file tree
Hide file tree
Showing 5 changed files with 13 additions and 4 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->


- [0.6.4](#064)
- [0.6.3](#063)
- [0.6.2](#062)
- [0.6.1](#061)
Expand All @@ -12,6 +13,9 @@

-----

# 0.6.4
Fixed version comparison function bug

# 0.6.3
Added changelog button to GM menu

Expand Down
2 changes: 1 addition & 1 deletion battered-shield-helper.meta.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
// ==UserScript==
// @name Battered shield helper
// @namespace https://github.com/AlorelUserscripts/battered-shield-notifier
// @version 0.6.3
// @version 0.6.4
// @downloadURL https://raw.githubusercontent.com/AlorelUserscripts/battered-shield-notifier/master/battered-shield-helper.user.js
// @updateURL https://raw.githubusercontent.com/AlorelUserscripts/battered-shield-notifier/master/battered-shield-helper.meta.js
// ==/UserScript==
4 changes: 2 additions & 2 deletions battered-shield-helper.user.js

Large diffs are not rendered by default.

5 changes: 5 additions & 0 deletions inc/version-compare.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
// Credit: https://jsfiddle.net/ripper234/Xv9WL/28/

const isPositiveInteger = (x) => {
// http://stackoverflow.com/a/1019526/11236
return /^\d+$/.test(x);
};

module.exports = (v1, v2) => {
let v1parts = v1.split('.');
let v2parts = v2.split('.');
Expand Down
2 changes: 1 addition & 1 deletion metablock.txt
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
// ==UserScript==
// @name Battered shield helper
// @namespace https://github.com/AlorelUserscripts/battered-shield-notifier
// @version 0.6.3
// @version 0.6.4
// @description Helps with your battered shields
// @author Alorel
// @include /^https?:\/\/(?=www\.)?batteredshield\.com\/game\/?/
Expand Down

0 comments on commit 6f6f5f2

Please sign in to comment.