Fixed: Prevent Bookshelf error if items is undefined

pull/770/head
Qstick 4 years ago
parent 7cc9a67b74
commit 8adf67ed5a

@ -16,7 +16,7 @@ function createMapStateToProps() {
...otherState ...otherState
} = bookshelves; } = bookshelves;
return ({ return ({
helptext: items.helptext && items.helptext[name] ? items.helptext[name] : '', helptext: items && items.helptext && items.helptext[name] ? items.helptext[name] : '',
user: items && items.user ? items.user : '', user: items && items.user ? items.user : '',
items: items && items.shelves ? items.shelves : [], items: items && items.shelves ? items.shelves : [],
...otherState ...otherState

Loading…
Cancel
Save