mirror of
https://github.com/metosin/reitit.git
synced 2026-02-23 02:19:09 +00:00
Polish code
This commit is contained in:
parent
3cdd4963ff
commit
9921479c46
1 changed files with 4 additions and 5 deletions
|
|
@ -66,7 +66,7 @@
|
||||||
(respond (handle request))))))
|
(respond (handle request))))))
|
||||||
|
|
||||||
(def default-options-endpoint
|
(def default-options-endpoint
|
||||||
{:no-doc true
|
{:no-doc true
|
||||||
:handler default-options-handler})
|
:handler default-options-handler})
|
||||||
|
|
||||||
;;
|
;;
|
||||||
|
|
@ -82,7 +82,7 @@
|
||||||
| ----------------------------------------|-------------
|
| ----------------------------------------|-------------
|
||||||
| `:reitit.middleware/transform` | Function or vector of functions of type `[Middleware] => [Middleware]` to transform the expanded Middleware (default: identity)
|
| `:reitit.middleware/transform` | Function or vector of functions of type `[Middleware] => [Middleware]` to transform the expanded Middleware (default: identity)
|
||||||
| `:reitit.middleware/registry` | Map of `keyword => IntoMiddleware` to replace keyword references into Middleware
|
| `:reitit.middleware/registry` | Map of `keyword => IntoMiddleware` to replace keyword references into Middleware
|
||||||
| `:reitit.ring/default-options-endpoint` | Default resource for `:options` method in endpoints (default: default-options-endpoint)
|
| `:reitit.ring/default-options-endpoint` | Default endpoint for `:options` method in endpoints (default: default-options-endpoint)
|
||||||
|
|
||||||
Example:
|
Example:
|
||||||
|
|
||||||
|
|
@ -100,9 +100,8 @@
|
||||||
::default-options-endpoint default-options-endpoint}
|
::default-options-endpoint default-options-endpoint}
|
||||||
opts)]
|
opts)]
|
||||||
(assert (not (contains? opts ::default-options-handler))
|
(assert (not (contains? opts ::default-options-handler))
|
||||||
(str
|
(str "Option `" ::default-options-handler "` is deprecated."
|
||||||
"Option `:reitit.ring/default-options-handler` is deprecated."
|
" Use `:" ::default-options-endpoint "` instead."))
|
||||||
" Use `:reitit.ring/default-options-endpoint` instead."))
|
|
||||||
(r/router data opts))))
|
(r/router data opts))))
|
||||||
|
|
||||||
(defn routes
|
(defn routes
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue