summaryrefslogtreecommitdiff
path: root/src/utils.clj
diff options
context:
space:
mode:
Diffstat (limited to 'src/utils.clj')
-rwxr-xr-xsrc/utils.clj7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/utils.clj b/src/utils.clj
index 3180e89..7abed4f 100755
--- a/src/utils.clj
+++ b/src/utils.clj
@@ -13,6 +13,13 @@
:user "postgres"
:password "root"}))
+
+(defn kbytes [b]
+ (* b 1024))
+
+(defn mbytes [b]
+ (* b 1024 1024))
+
;; JSON responses
(def yyyy-mm-dd-formatter (new SimpleDateFormat "yyyy-MM-dd"))