diff --git a/client/homebrew/pages/archivePage/archivePage.jsx b/client/homebrew/pages/archivePage/archivePage.jsx index 7b3f6c40d..765fe1f38 100644 --- a/client/homebrew/pages/archivePage/archivePage.jsx +++ b/client/homebrew/pages/archivePage/archivePage.jsx @@ -41,7 +41,7 @@ const ArchivePage = createClass({ this.setState({ searching: true, error: null }); request .get(`/archive/${this.state.title}`) - .then((res) => this.setState({ brewCollection: res.body.brews }, this.setState({ limit: res.body.message}))) + .then((res) => this.setState({ brewCollection: res.body.brews }, this.setState({ limit: res.body.message}, this.setState({ error: null})))) .catch((err) => this.setState({ error: err })) .finally(() => this.setState({ searching: false })); }, @@ -62,6 +62,14 @@ const ArchivePage = createClass({ renderFoundBrews() { const brews = this.state.brewCollection; console.log('brews: ',brews); + if (this.state.error !== null) { + return( +
Your search is not enough specific, too many brews meet this criteria for us to forward them.
+