If debug interceptor was "to the left" of path, debug would not show correct diffs. Make path reinstate effect to fix this.

This commit is contained in:
Mike Thompson 2016-08-09 19:22:15 +10:00
parent 28afe57b96
commit e45fd8b858
1 changed files with 2 additions and 1 deletions

View File

@ -167,7 +167,8 @@
(let [db-store (db-store-key context)
original-db (peek db-store)
new-db-store (pop db-store)
context' (assoc context db-store-key new-db-store)
context' (-> (assoc context db-store-key new-db-store)
(assoc-coeffect :db original-db)) ;; put the original db back so that things like debug work later on
db (get-effect context :db ::not-found)]
(if (= db ::not-found)
context'