Sales nearly ready
This commit is contained in:
@@ -439,10 +439,14 @@
|
||||
:explain
|
||||
(me/humanize {:errors (assoc me/default-errors
|
||||
::mc/missing-key {:error/message {:en "required"}})}))
|
||||
(map (fn [[k v]]
|
||||
(str (if (keyword? k)
|
||||
(name k)
|
||||
k) ": " (str/join ", " v))))
|
||||
(map (fn [x]
|
||||
(if (and (sequential? x)
|
||||
(= (count x) 2))
|
||||
(let [[k v] x]
|
||||
(str (if (keyword? k)
|
||||
(name k)
|
||||
k) ": " (str/join ", " v))
|
||||
(str x)))))
|
||||
(str/join ", "))
|
||||
{:type :schema-validation
|
||||
:decoded (:value (:data (ex-data e)))
|
||||
@@ -539,7 +543,8 @@
|
||||
{:path (:in e)
|
||||
:message (get-in humanized (:in e))})
|
||||
(:errors (:explain (:error e))))]
|
||||
(alog/warn ::form-4xx :errors errors)
|
||||
(alog/warn ::form-4xx :errors errors
|
||||
:data e)
|
||||
(form-handler (assoc request
|
||||
:form-params (:decoded e)
|
||||
:field-validation-errors errors
|
||||
|
||||
Reference in New Issue
Block a user