diff --git a/src/App.js b/src/App.js index 596748b..6d45d2f 100755 --- a/src/App.js +++ b/src/App.js @@ -37,6 +37,10 @@ class BooksApp extends React.Component { books: [...this.state.books, newBook] }); }); + const newBooks = this.state.books + newBooks.forEach((book) => { + update(book, book.shelf) + }) } onSelectChange = (e) => { diff --git a/src/SearchPage.js b/src/SearchPage.js index 7065ab0..724d39a 100644 --- a/src/SearchPage.js +++ b/src/SearchPage.js @@ -37,12 +37,12 @@ class SearchPage extends Component {