0
0
mirror of https://github.com/naturalcrit/homebrewery.git synced 2025-12-24 18:32:41 +00:00

Removing the ability for the changelog to get into the recent brews

This commit is contained in:
Scott Tolksdorf
2016-06-04 18:30:26 -04:00
parent 7ca4e8ffa6
commit d2a9b3f274

View File

@@ -30,12 +30,14 @@ var BaseItem = React.createClass({
brews = _.filter(brews, (brew)=>{
return brew.id !== this.props.currentBrew.id;
});
brews.unshift({
id : this.props.currentBrew.id,
url : this.props.currentBrew.url,
title : this.props.currentBrew.title,
ts : Date.now()
});
if(this.props.currentBrew.id){
brews.unshift({
id : this.props.currentBrew.id,
url : this.props.currentBrew.url,
title : this.props.currentBrew.title,
ts : Date.now()
});
}
brews = _.slice(brews, 0, 8);
localStorage.setItem(this.props.storageKey, JSON.stringify(brews));
this.setState({