minor refactoring

This commit is contained in:
Gered 2014-06-01 16:45:22 -04:00
parent 03f58d5b93
commit 12aabb6fd8

View file

@ -15,12 +15,15 @@
(let [uri (new URI url)]
(str/blank? (.getScheme uri)))))
(defn- get-url-string [url]
(if-let [modification-timestamp (if (relative-url? url)
(defn- get-resource-modification-timestamp [^String resource-url]
(if (relative-url? resource-url)
;; TODO: while 'public' is the default with Compojure, applications can override with something else ...
(->> (str "public" url)
(->> (str "public" resource-url)
(get-context-url)
(get-resource-modification-date)))]
(get-resource-modification-date))))
(defn- get-url-string [url]
(if-let [modification-timestamp (get-resource-modification-timestamp url)]
(str url "?" modification-timestamp)
url))