Merge pull request #584 from clyfish/fix-base54

fix base54
This commit is contained in:
Richard van Velzen
2015-01-04 14:00:23 +01:00

View File

@@ -471,7 +471,9 @@ var base54 = (function() {
base54.freq = function(){ return frequency };
function base54(num) {
var ret = "", base = 54;
num++;
do {
num--;
ret += String.fromCharCode(chars[num % base]);
num = Math.floor(num / base);
base = 64;