From f3ed336278284c81c64c28dad11a74e725265349 Mon Sep 17 00:00:00 2001 From: Christopher Jeffrey Date: Tue, 16 Sep 2014 09:57:21 -0700 Subject: [PATCH] paypro: minor fix to createPaymentTx callback. --- js/models/core/Wallet.js | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/js/models/core/Wallet.js b/js/models/core/Wallet.js index 107ad366a..a57acabac 100644 --- a/js/models/core/Wallet.js +++ b/js/models/core/Wallet.js @@ -1303,7 +1303,14 @@ Wallet.prototype.createPaymentTx = function(options, cb) { return self.receivePaymentRequest(options, pr, cb); }) .error(function(data, status, headers, config) { - return cb(new Error('Status: ' + status)); + log.debug('Server was did not return PaymentRequest.'); + log.debug('XHR status: ' + status); + if (options.fetch) { + return cb(new Error('Status: ' + status)); + } else { + // Should never happen: + return cb(null, null, null); + } }); };