Skip to content

Commit

Permalink
Removed stuff I am not using.
Browse files Browse the repository at this point in the history
  • Loading branch information
MayDaniel committed Sep 1, 2010
1 parent e6bce5f commit 9739e0c
Showing 1 changed file with 5 additions and 8 deletions.
13 changes: 5 additions & 8 deletions src/clj_chat/core.clj
Original file line number Diff line number Diff line change
Expand Up @@ -35,9 +35,6 @@
(defn dissoc-in [map [& ks] key & keys]
(apply update-in map ks dissoc key keys))

(defn id?<- [coll]
(filter identity coll))

(defn date->str
([] (date->str (now)))
([date] (-> date to-date str (subs 0 19))))
Expand All @@ -46,6 +43,11 @@
(println (str "(" (date->str) ")"
"[" room "] " user ": " message)))

(defn interval->now [date]
(let [[seconds minutes] ((juxt in-minutes in-secs)
(interval date (now)))]
(join " " [minutes "minutes" (mod seconds 60) "seconds"])))

(defn last-input []
(when-let [in-as (:in-as @*session*)]
(db/update-user! in-as merge {:last-input (unparse format-time (now))})))
Expand Down Expand Up @@ -151,11 +153,6 @@ specified, prints the help string and argument list for it."
"You've successfully logged out.")
"You're not logged in."))

(defn interval->now [date]
(let [[seconds minutes] ((juxt in-minutes in-secs)
(interval date (now)))]
(join " " [minutes "minutes" (mod seconds 60) "seconds"])))

(defcommand Whois
"Shows information about the user."
[username]
Expand Down

0 comments on commit 9739e0c

Please sign in to comment.