Skip to content
Snippets Groups Projects
Commit 966eb157 authored by Cam Saul's avatar Cam Saul
Browse files

don't "serialize" :created_at or :updated_at

parent d5adfe2f
Branches
Tags
No related merge requests found
......@@ -30,7 +30,8 @@
(extend-protocol IRevisioned
Object
(serialize-instance [_ _ instance]
(->> (into {} instance)
(->> (dissoc instance :created_at :updated_at)
(into {}) ; if it's a record type like CardInstance we need to convert it to a regular map or filter-vals won't work
(m/filter-vals (complement delay?))))
(revert-to-revision [entity id serialized-instance]
(m/mapply upd entity id serialized-instance))
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment