fix exception on :clear-pending-transactions

This commit is contained in:
Roman Volosovskyi 2017-04-11 13:10:35 +03:00
parent 2320869055
commit 7a70d90d5e
2 changed files with 5 additions and 2 deletions

View File

@ -14,7 +14,7 @@
<body>
<div id="app">
</div>
<script src="js/compiled/app.js?v=56d0cf2d87180ee88e1a10e6c0e75cbde1b4798d"></script>
<script src="js/compiled/app.js?v=232086905532ceacb15ba64c3b4491e98889d927"></script>
<script>token.core.init();</script>
</body>
</html>

View File

@ -148,4 +148,7 @@
(register-handler
:clear-pending-transactions
(fn [db [_ account hashes]]
(update-in db [:pending-transactions account] apply dissoc hashes)))
(update-in db [:pending-transactions account]
(fn [transactions]
(when transactions
(apply dissoc transactions hashes))))))