Skip to content

Instantly share code, notes, and snippets.

@KirinDave
Created November 19, 2010 19:18
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save KirinDave/706981 to your computer and use it in GitHub Desktop.
Save KirinDave/706981 to your computer and use it in GitHub Desktop.
(defn date-for-request-header [request header-name]
(when-let [val (-> request :headers (get (.toLowerCase header-name)))]
(when-let [[t tz] (date-timezone-from-string val)]
(when (#{"UTC" "GMT"} tz)
t))))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment