Don't show history nav if 404ing

This commit is contained in:
Nick Pegg 2017-10-07 17:53:03 -07:00
parent 6b0c0f2d88
commit 4743912d9d

View file

@ -232,17 +232,17 @@ class Posts extends Component {
/> />
); );
let jawn = articles; let jawn = (
<div>
{articles}
<HistoryNav prev={this.state.prevHref} next={this.state.nextHref} />
</div>
)
if (articles.length === 0) { if (articles.length === 0) {
jawn = <NotFound />; jawn = <NotFound />;
} }
return ( return jawn
<div>
{ jawn }
<HistoryNav prev={this.state.prevHref} next={this.state.nextHref} />
</div>
)
} else { } else {
return <p></p> return <p></p>
} }