Created
February 27, 2014 04:18
-
-
Save yayitswei/9244307 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(defn wrap-exception [f] | |
(fn [request] | |
(try (f request) | |
(catch Exception e | |
{:status 500 | |
:body "Exception caught"})))) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment