From f96b124346ca353c8256fb048f96d5203fb5e709 Mon Sep 17 00:00:00 2001 From: Sigve Date: Fri, 2 Mar 2018 22:44:08 +0000 Subject: [PATCH] Fix for margin positions modal not showing existing positions --- app/components/Modal/BorrowModal.jsx | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/app/components/Modal/BorrowModal.jsx b/app/components/Modal/BorrowModal.jsx index 2ebc083ec9..1917b27b9b 100755 --- a/app/components/Modal/BorrowModal.jsx +++ b/app/components/Modal/BorrowModal.jsx @@ -343,10 +343,14 @@ class BorrowModalContent extends React.Component { a.getIn(["call_price", "quote", "asset_id"]) === props.quote_asset.get("id") ); - }) || { - collateral: null, - debt: null - }; + }); + + currentPosition = !!currentPosition + ? currentPosition.toJS() + : { + collateral: null, + debt: null + }; } return currentPosition; }