Skip to content

Notifications / Sounds #56

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 8 commits into from
Jun 13, 2015
Merged

Notifications / Sounds #56

merged 8 commits into from
Jun 13, 2015

Conversation

manosim
Copy link
Member

@manosim manosim commented Jun 12, 2015

No description provided.

@manosim manosim added this to the Release 0.0.13 milestone Jun 12, 2015
@manosim manosim mentioned this pull request Jun 12, 2015
var isNew = false;
_.map(response, function (obj) {
if (!_.contains(self._previousNotifications, obj.id)) {
isNew = true;
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

To keep this function pure you should use _.some (also has alias _.any)...

var isNew = _.some(response, function (obj) {
  return !_.contains(self._previousNotifications, obj.id);
});

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As discussed will have a further look in cleaning it up on #57 .

@manosim manosim added release Release and removed review needed labels Jun 13, 2015
manosim pushed a commit that referenced this pull request Jun 13, 2015
@manosim manosim merged commit 5e78c37 into master Jun 13, 2015
@manosim manosim deleted the play-sound branch June 13, 2015 17:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
release Release
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants