Skip to content

Instantly share code, notes, and snippets.

@christianberg
Created June 9, 2010 15:33
Show Gist options
  • Save christianberg/431653 to your computer and use it in GitHub Desktop.
Save christianberg/431653 to your computer and use it in GitHub Desktop.
(defroutes login-routes
(GET "/_ah/login" [continue] (login-form continue))
(POST "/_ah/login" [action email isAdmin continue] (do (if (= action "Log In")
(login email (boolean isAdmin))
(logout))
(redirect continue)))
(GET "/_ah/logout" [continue] (do (logout)
(redirect continue))))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment