Skip to content

Commit

Permalink
Merge pull request #394 from cloudstech/master
Browse files Browse the repository at this point in the history
Fix: Library was changing badge: 0 to badge: undefined
  • Loading branch information
argon committed Jun 25, 2016
2 parents 576dc6d + 0fa7cf0 commit da6c418
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/notification.js
Expand Up @@ -480,7 +480,7 @@ Notification.prototype.truncateStringToLength = function (string, length, encodi
Notification.prototype.apsPayload = function() {
var aps = this.payload.aps || {};

aps.badge = this.badge || aps.badge;
aps.badge = typeof this.badge !== "undefined" ? this.badge : aps.badge;
aps.sound = this.sound || aps.sound;
aps.alert = this.alert || aps.alert;
if (this.contentAvailable) {
Expand Down

0 comments on commit da6c418

Please sign in to comment.