pushwoosh-client
Advanced tools
Comparing version 1.2.0 to 1.2.1
19
index.js
@@ -22,3 +22,3 @@ var request = require('request'), | ||
}; | ||
} | ||
@@ -50,2 +50,8 @@ PushwooshClient.prototype.sendMessage = function (msg, device, options, callback) { | ||
var defaultOptions = { | ||
send_date: 'now', | ||
ignore_user_timezone: true, | ||
content: msg | ||
}; | ||
var devices = []; | ||
@@ -61,8 +67,5 @@ | ||
var defaultOptions = { | ||
send_date: 'now', | ||
ignore_user_timezone: true, | ||
content: msg, | ||
devices: devices | ||
}; | ||
if (device) { | ||
defaultOptions.devices = devices; | ||
} | ||
@@ -112,3 +115,3 @@ var notification = extend(defaultOptions, options); | ||
client.parseResponse(response, body, callback); | ||
}) | ||
}); | ||
}; | ||
@@ -115,0 +118,0 @@ |
{ | ||
"name": "pushwoosh-client", | ||
"version": "1.2.0", | ||
"version": "1.2.1", | ||
"description": "A node js client to consume the Pushwoosh API to send push notifications to mobile devices", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
@@ -18,3 +18,3 @@ var test = require('tape'), | ||
fraudster.registerMock('request', {}); | ||
fraudster.registerMock('../lib/errors', errors); | ||
fraudster.registerMock('./lib/errors', errors); | ||
} | ||
@@ -124,4 +124,3 @@ | ||
ignore_user_timezone: true, | ||
content: testMsg, | ||
devices: [] | ||
content: testMsg | ||
}] | ||
@@ -166,4 +165,3 @@ } | ||
ignore_user_timezone: true, | ||
content: testMsg, | ||
devices: [] | ||
content: testMsg | ||
}] | ||
@@ -253,4 +251,3 @@ } | ||
ignore_user_timezone: true, | ||
content: testMsg, | ||
devices: [] | ||
content: testMsg | ||
}] | ||
@@ -297,4 +294,3 @@ } | ||
ignore_user_timezone: true, | ||
content: testMsg, | ||
devices: [] | ||
content: testMsg | ||
}] | ||
@@ -572,4 +568,3 @@ } | ||
ignore_user_timezone: true, | ||
content: testMsg, | ||
devices: [] | ||
content: testMsg | ||
}] | ||
@@ -614,4 +609,3 @@ } | ||
ignore_user_timezone: true, | ||
content: testMsg, | ||
devices: [] | ||
content: testMsg | ||
}] | ||
@@ -618,0 +612,0 @@ } |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
47092
1094