From cfd50fe701666db3bbaa2d800251f7691597740a Mon Sep 17 00:00:00 2001 From: Vesa Luusua Date: Fri, 16 Mar 2018 12:05:01 +0200 Subject: [PATCH] InboxPage: check that user is available --- src/containers/InboxPage/InboxPage.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/containers/InboxPage/InboxPage.js b/src/containers/InboxPage/InboxPage.js index 4e0073ac..9cc00ec0 100644 --- a/src/containers/InboxPage/InboxPage.js +++ b/src/containers/InboxPage/InboxPage.js @@ -288,8 +288,8 @@ export const InboxPageComponent = props => { const hasOrderOrSaleTransactions = (tx, isOrdersTab, user) => { return isOrdersTab - ? tx && tx.length > 0 && tx[0].customer.id.uuid === user.id.uuid - : tx && tx.length > 0 && tx[0].provider.id.uuid === user.id.uuid; + ? user.id && tx && tx.length > 0 && tx[0].customer.id.uuid === user.id.uuid + : user.id && tx && tx.length > 0 && tx[0].provider.id.uuid === user.id.uuid; }; const hasTransactions = !fetchInProgress && hasOrderOrSaleTransactions(transactions, isOrders, currentUser);