Merge pull request #73 from alDuncanson/bugfix/list

The actual last PR
This commit is contained in:
Alex Duncanson
2018-12-12 00:34:35 -05:00
committed by GitHub
2 changed files with 133 additions and 151 deletions

View File

@@ -353,7 +353,7 @@ class ResponsiveDrawer extends React.Component {
<Route path="/" component={Home} exact={true} />
<Route path="/report" component={Report} />
<Route path="/view-map" component={ViewMap} />
<Route path="/sighting-list" component={SightingList} />
<Route path="/sighting-list" component={SightingList} key={this.state.themeName} />
<Route path="/about" component={About} />
<Route path="/contact" component={Contact} />
<Route path="/quiz-easy" component={Quiz} key={"Easy"} />

View File

@@ -64,24 +64,6 @@ class ViewSightings extends Component {
clicked: false
};
componentDidUpdate(props) {
if (this.props.themeName !== props.themeName) {
this.setState({
selectedSighting: {
id: null,
lat: null,
lng: null,
desc: null,
type: null,
confidence: null,
date: null,
time: null
},
clicked: false
});
}
}
render() {
return (
<Fragment>