Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions lib/paypal-common.es6
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ PayPal.config.attachSchema(new SimpleSchema({

// David Morales on SO - http://stackoverflow.com/a/11582513
getURLParameter = function(name){
return decodeURIComponent((new RegExp('[?|&]' + name + '=' + '([^&;]+?)(&|#|;|$)').exec(location.search)||[,""])[1].replace(/\+/g, '%20'))||null;
return decodeURIComponent((new RegExp('[?|&]' + name + '=' + '([^&;]+?)(&|#|;|$)').exec(location.search)||[null,""])[1].replace(/\+/g, '%20'))||null;
};

result = function(r){
Expand Down Expand Up @@ -145,4 +145,4 @@ PayPal.onPaymentFailure = function(cb){

// Stubs
PayPal._onPaymentError = function(){};
PayPal._onPaymentSuccess = function(){};
PayPal._onPaymentSuccess = function(){};