Skip to content

Commit

Permalink
add back routes/create
Browse files Browse the repository at this point in the history
  • Loading branch information
frenchy64 committed Apr 22, 2024
1 parent cc937b4 commit fa5fb01
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,9 @@ See also: [compojure-api 1.1.x changelog](./CHANGELOG-1.1.x.md)
## Unreleased

* Fix empty spec response coercion. [#413](https://github.com/metosin/compojure-api/issues/413)
* Add back `defapi` (and deprecate it)
* Remove potemkin [#445](https://github.com/metosin/compojure-api/issues/445)
* Add back `compojure.api.routes/create`

## 2.0.0-alpha31 (2019-12-20)

Expand Down
3 changes: 3 additions & 0 deletions src/compojure/api/routes.clj
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,9 @@
(applyTo [this args]
(AFn/applyToHelper this args)))

(defn create [path method info childs handler]
(->Route path method info childs handler))

(defmethod print-method Route
[this ^Writer w]
(let [childs (some-> this realize-childs filter-childs :childs seq vec)]
Expand Down

0 comments on commit fa5fb01

Please sign in to comment.