From 8eecc92fbd468f7e48831562a5c4d7464df77a9b Mon Sep 17 00:00:00 2001 From: Andrew Yochum Date: Thu, 16 Jul 2015 17:09:39 -0400 Subject: [PATCH 1/2] Fixed invalid object instantiation attempts --- lib/interface/client.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/interface/client.js b/lib/interface/client.js index 17504a3..297b46a 100644 --- a/lib/interface/client.js +++ b/lib/interface/client.js @@ -58,7 +58,7 @@ Client.prototype = { }, getListsForEmail: function (emailAddress, callback) { - this.createsend.get('clients/' + this.clientId + '/listsforemail.json', new { 'email': emailAddress }, null, callback); + this.createsend.get('clients/' + this.clientId + '/listsforemail.json', { 'email': emailAddress }, null, callback); }, getScheduledCampaigns: function (callback) { @@ -99,7 +99,7 @@ Client.prototype = { }, suppress: function (emailAddress, callback) { - this.createsend.post('clients/' + this.clientId + '/suppress.json', null, new { 'EmailAddress': emailAddress }, callback); + this.createsend.post('clients/' + this.clientId + '/suppress.json', null, { 'EmailAddress': emailAddress }, callback); }, transferCredits: function (details, callback) { @@ -112,6 +112,6 @@ Client.prototype = { }, unsuppress: function (emailAddress, callback) { - this.createsend.put('clients/' + this.clientId + '/unsuppress.json', new { 'email': emailAddress }, null, callback); + this.createsend.put('clients/' + this.clientId + '/unsuppress.json', { 'email': emailAddress }, null, callback); } } From dfdb4c08326820f3c7e9baecb1b3daf3c31e6ebd Mon Sep 17 00:00:00 2001 From: Andrew Yochum Date: Thu, 16 Jul 2015 17:10:04 -0400 Subject: [PATCH 2/2] Added missing emailAddress parameter for getListsForEmail --- lib/interface/clients.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/interface/clients.js b/lib/interface/clients.js index 0bc79b7..a0077ad 100644 --- a/lib/interface/clients.js +++ b/lib/interface/clients.js @@ -52,7 +52,7 @@ Clients.prototype = { new Client(this.createsend, clientId).getPrimaryContact(callback); }, - getListsForEmail: function (clientId, callback) { + getListsForEmail: function (clientId, emailAddress, callback) { new Client(this.createsend, clientId).getListsForEmail(emailAddress, callback); },