diff options
author | P. J. McDermott <pj@pehjota.net> | 2015-03-16 15:08:16 (EDT) |
---|---|---|
committer | P. J. McDermott <pj@pehjota.net> | 2015-03-16 15:08:16 (EDT) |
commit | e11cb0820f20d0c847961b47282fc98110b5fd86 (patch) | |
tree | b68c93a6a2b6ac9e658901fae3c5c9cc2b7a6830 | |
parent | 0af3d76e7dfba5fb6eb63ebc4d8baf79743973eb (diff) | |
download | epirts.js-e11cb0820f20d0c847961b47282fc98110b5fd86.zip epirts.js-e11cb0820f20d0c847961b47282fc98110b5fd86.tar.gz epirts.js-e11cb0820f20d0c847961b47282fc98110b5fd86.tar.bz2 |
Epirts.card.createToken(): Fix callback signatures
-rw-r--r-- | README | 3 | ||||
-rw-r--r-- | epirts.js | 4 |
2 files changed, 5 insertions, 2 deletions
@@ -30,6 +30,9 @@ Methods cvc: '123' }, stripeResponseHandler); + The callback function will be given two arguments, a `status` code and a + `response` object. + * `Epirts.card.validateCardNumber(number)` Checks that the card number appears valid and passes the Luhn check. @@ -78,8 +78,8 @@ var Stripe = Epirts = (function() { script.async = true; func = 'sjsonp' + ++_cb_time; - window[func] = function(result) { - callback(result); + window[func] = function(response, status) { + callback(status, response); script.parentNode.removeChild(script); } |