diff --git a/src/js/utilJS.tw b/src/js/utilJS.tw index f266637675f911f02fe5cbc6fda5257bcbaf773d..60e1b6694f38a4d2edd7df6b8df536cf04a730f2 100644 --- a/src/js/utilJS.tw +++ b/src/js/utilJS.tw @@ -401,11 +401,11 @@ window.numberWithCommas = function(x) { } -window.random = function(min,max) { +window.jsRandom = function(min,max) { return Math.floor(Math.random()*(max-min+1)+min); } -window.randomMany = function (arr, count) { +window.jsRandomMany = function (arr, count) { var result = []; var _tmp = arr.slice(); for (var i = 0; i < count; i++) { @@ -415,7 +415,7 @@ window.randomMany = function (arr, count) { return result; } -window.either = function(choices) { +window.jsEither = function(choices) { var index = Math.floor(Math.random() * choices.length); return choices[index]; }