ponymail-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From humbed...@apache.org
Subject [1/2] incubator-ponymail git commit: padding
Date Thu, 08 Sep 2016 06:08:10 GMT
Repository: incubator-ponymail
Updated Branches:
  refs/heads/coffee-and-cake ae791c1a6 -> 20031f532


padding


Project: http://git-wip-us.apache.org/repos/asf/incubator-ponymail/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-ponymail/commit/5baa9534
Tree: http://git-wip-us.apache.org/repos/asf/incubator-ponymail/tree/5baa9534
Diff: http://git-wip-us.apache.org/repos/asf/incubator-ponymail/diff/5baa9534

Branch: refs/heads/coffee-and-cake
Commit: 5baa9534da5a055adb7d311bd4a29205eb7f00de
Parents: ae791c1
Author: Daniel Gruno <humbedooh@apache.org>
Authored: Thu Sep 8 08:07:35 2016 +0200
Committer: Daniel Gruno <humbedooh@apache.org>
Committed: Thu Sep 8 08:07:35 2016 +0200

----------------------------------------------------------------------
 site/js/coffee/misc.coffee | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ponymail/blob/5baa9534/site/js/coffee/misc.coffee
----------------------------------------------------------------------
diff --git a/site/js/coffee/misc.coffee b/site/js/coffee/misc.coffee
index 2ac684c..8d94389 100644
--- a/site/js/coffee/misc.coffee
+++ b/site/js/coffee/misc.coffee
@@ -105,7 +105,7 @@ shortenURL = (mid) ->
             num = parseInt(a, 16)
             res = num.toString(36)
             while res.length < 7
-                res = '0' + res
+                res = '-' + res
             out += res
         return "PZ" + out
     
@@ -115,7 +115,7 @@ unshortenURL = (mid) ->
     if mid.substr(0,2) == 'PZ'
         out = ""
         for i in [0..shortBits-1]
-            num = parseInt(mid.substr(2+(i*7), 7), 36)
+            num = parseInt(mid.substr(2+(i*7), 7).replace('-', ''), 36)
             res = num.toString(16)
             while res.length < 8
                 res = '0' + res


Mime
View raw message