Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
frenchy64 committed Jul 9, 2024
1 parent d49828b commit a3def99
Showing 1 changed file with 3 additions and 17 deletions.
20 changes: 3 additions & 17 deletions src/ring/swagger/json_schema.clj
Original file line number Diff line number Diff line change
Expand Up @@ -277,31 +277,17 @@
The result is put into collection of same type as input schema.
Thus linked/map should keep the order of items. Returns nil
if no properties are found."
<<<<<<< HEAD
([schema] (properties schema nil))
([schema opts]
{:pre [(common/plain-map? schema)]}
(let [props (into (empty schema)
(for [[k v] schema
:when (s/specific-key? k)
:let [key-meta (meta k)
k (s/explicit-schema-key k)]
:let [v (try->swagger v k key-meta opts)]]
k (s/explicit-schema-key k)
v (try->swagger v k key-meta opts)]]
(and v [k v])))]
(if (seq props)
props))))
=======
[schema]
{:pre [(common/plain-map? schema)]}
(let [props (into (empty schema)
(for [[k v] schema
:when (s/specific-key? k)
:let [key-meta (meta k)
k (s/explicit-schema-key k)
v (try->swagger v k key-meta)]]
(and v [k v])))]
(not-empty props)))
>>>>>>> master
(not-empty props))))

(defn additional-properties
"Generates json-schema additional properties from a plain map
Expand Down

0 comments on commit a3def99

Please sign in to comment.