@paystack/checkout-js 1.23.0-dev.1 → 1.23.0-dev.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/checkout.js +13 -4
- package/es/checkout.js +13 -4
- package/lib/checkout.js +13 -4
- package/package.json +1 -1
package/dist/checkout.js
CHANGED
|
@@ -21020,6 +21020,7 @@ var Paystack = (function (exports) {
|
|
|
21020
21020
|
var chargeParams = {
|
|
21021
21021
|
clientdata: _this2.card.tokenize(),
|
|
21022
21022
|
last4: _this2.card.getLast4(),
|
|
21023
|
+
device: _this2.deviceFingerprint,
|
|
21023
21024
|
preauthorizationId: preauthorizationId,
|
|
21024
21025
|
publicKey: publicKey,
|
|
21025
21026
|
customFields: customFields
|
|
@@ -21265,6 +21266,7 @@ var Paystack = (function (exports) {
|
|
|
21265
21266
|
this.channels = data.channels || ['card'];
|
|
21266
21267
|
this.isListening = false;
|
|
21267
21268
|
this.isTest = data.domain === 'test';
|
|
21269
|
+
this.deviceFingerprint = data.deviceFingerprint || null;
|
|
21268
21270
|
this.merchant = {
|
|
21269
21271
|
id: data.merchant_id,
|
|
21270
21272
|
logo: data.merchant_logo,
|
|
@@ -21309,19 +21311,26 @@ var Paystack = (function (exports) {
|
|
|
21309
21311
|
},
|
|
21310
21312
|
getByAccessCode: function getByAccessCode(accessCode) {
|
|
21311
21313
|
return _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee() {
|
|
21312
|
-
var response;
|
|
21314
|
+
var deviceFingerprint, response;
|
|
21313
21315
|
return regeneratorRuntime.wrap(function _callee$(_context) {
|
|
21314
21316
|
while (1) {
|
|
21315
21317
|
switch (_context.prev = _context.next) {
|
|
21316
21318
|
case 0:
|
|
21317
21319
|
_context.next = 2;
|
|
21318
|
-
return
|
|
21320
|
+
return getDeviceFingerprint();
|
|
21319
21321
|
|
|
21320
21322
|
case 2:
|
|
21323
|
+
deviceFingerprint = _context.sent;
|
|
21324
|
+
_context.next = 5;
|
|
21325
|
+
return PreauthorisationAPI.getByAccessCode(accessCode);
|
|
21326
|
+
|
|
21327
|
+
case 5:
|
|
21321
21328
|
response = _context.sent;
|
|
21322
|
-
return _context.abrupt("return", response && Object.seal(new PreauthorizationInstance(_objectSpread2({}, response.data)
|
|
21329
|
+
return _context.abrupt("return", response && Object.seal(new PreauthorizationInstance(_objectSpread2(_objectSpread2({}, response.data), {}, {
|
|
21330
|
+
deviceFingerprint: deviceFingerprint
|
|
21331
|
+
}))));
|
|
21323
21332
|
|
|
21324
|
-
case
|
|
21333
|
+
case 7:
|
|
21325
21334
|
case "end":
|
|
21326
21335
|
return _context.stop();
|
|
21327
21336
|
}
|
package/es/checkout.js
CHANGED
|
@@ -21017,6 +21017,7 @@ var CardPreauthorization = {
|
|
|
21017
21017
|
var chargeParams = {
|
|
21018
21018
|
clientdata: _this2.card.tokenize(),
|
|
21019
21019
|
last4: _this2.card.getLast4(),
|
|
21020
|
+
device: _this2.deviceFingerprint,
|
|
21020
21021
|
preauthorizationId: preauthorizationId,
|
|
21021
21022
|
publicKey: publicKey,
|
|
21022
21023
|
customFields: customFields
|
|
@@ -21262,6 +21263,7 @@ var PreauthorizationInstance = /*#__PURE__*/function () {
|
|
|
21262
21263
|
this.channels = data.channels || ['card'];
|
|
21263
21264
|
this.isListening = false;
|
|
21264
21265
|
this.isTest = data.domain === 'test';
|
|
21266
|
+
this.deviceFingerprint = data.deviceFingerprint || null;
|
|
21265
21267
|
this.merchant = {
|
|
21266
21268
|
id: data.merchant_id,
|
|
21267
21269
|
logo: data.merchant_logo,
|
|
@@ -21306,19 +21308,26 @@ var Preauthorization = {
|
|
|
21306
21308
|
},
|
|
21307
21309
|
getByAccessCode: function getByAccessCode(accessCode) {
|
|
21308
21310
|
return _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee() {
|
|
21309
|
-
var response;
|
|
21311
|
+
var deviceFingerprint, response;
|
|
21310
21312
|
return regeneratorRuntime.wrap(function _callee$(_context) {
|
|
21311
21313
|
while (1) {
|
|
21312
21314
|
switch (_context.prev = _context.next) {
|
|
21313
21315
|
case 0:
|
|
21314
21316
|
_context.next = 2;
|
|
21315
|
-
return
|
|
21317
|
+
return getDeviceFingerprint();
|
|
21316
21318
|
|
|
21317
21319
|
case 2:
|
|
21320
|
+
deviceFingerprint = _context.sent;
|
|
21321
|
+
_context.next = 5;
|
|
21322
|
+
return PreauthorisationAPI.getByAccessCode(accessCode);
|
|
21323
|
+
|
|
21324
|
+
case 5:
|
|
21318
21325
|
response = _context.sent;
|
|
21319
|
-
return _context.abrupt("return", response && Object.seal(new PreauthorizationInstance(_objectSpread2({}, response.data)
|
|
21326
|
+
return _context.abrupt("return", response && Object.seal(new PreauthorizationInstance(_objectSpread2(_objectSpread2({}, response.data), {}, {
|
|
21327
|
+
deviceFingerprint: deviceFingerprint
|
|
21328
|
+
}))));
|
|
21320
21329
|
|
|
21321
|
-
case
|
|
21330
|
+
case 7:
|
|
21322
21331
|
case "end":
|
|
21323
21332
|
return _context.stop();
|
|
21324
21333
|
}
|
package/lib/checkout.js
CHANGED
|
@@ -21021,6 +21021,7 @@ var CardPreauthorization = {
|
|
|
21021
21021
|
var chargeParams = {
|
|
21022
21022
|
clientdata: _this2.card.tokenize(),
|
|
21023
21023
|
last4: _this2.card.getLast4(),
|
|
21024
|
+
device: _this2.deviceFingerprint,
|
|
21024
21025
|
preauthorizationId: preauthorizationId,
|
|
21025
21026
|
publicKey: publicKey,
|
|
21026
21027
|
customFields: customFields
|
|
@@ -21266,6 +21267,7 @@ var PreauthorizationInstance = /*#__PURE__*/function () {
|
|
|
21266
21267
|
this.channels = data.channels || ['card'];
|
|
21267
21268
|
this.isListening = false;
|
|
21268
21269
|
this.isTest = data.domain === 'test';
|
|
21270
|
+
this.deviceFingerprint = data.deviceFingerprint || null;
|
|
21269
21271
|
this.merchant = {
|
|
21270
21272
|
id: data.merchant_id,
|
|
21271
21273
|
logo: data.merchant_logo,
|
|
@@ -21310,19 +21312,26 @@ var Preauthorization = {
|
|
|
21310
21312
|
},
|
|
21311
21313
|
getByAccessCode: function getByAccessCode(accessCode) {
|
|
21312
21314
|
return _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee() {
|
|
21313
|
-
var response;
|
|
21315
|
+
var deviceFingerprint, response;
|
|
21314
21316
|
return regeneratorRuntime.wrap(function _callee$(_context) {
|
|
21315
21317
|
while (1) {
|
|
21316
21318
|
switch (_context.prev = _context.next) {
|
|
21317
21319
|
case 0:
|
|
21318
21320
|
_context.next = 2;
|
|
21319
|
-
return
|
|
21321
|
+
return getDeviceFingerprint();
|
|
21320
21322
|
|
|
21321
21323
|
case 2:
|
|
21324
|
+
deviceFingerprint = _context.sent;
|
|
21325
|
+
_context.next = 5;
|
|
21326
|
+
return PreauthorisationAPI.getByAccessCode(accessCode);
|
|
21327
|
+
|
|
21328
|
+
case 5:
|
|
21322
21329
|
response = _context.sent;
|
|
21323
|
-
return _context.abrupt("return", response && Object.seal(new PreauthorizationInstance(_objectSpread2({}, response.data)
|
|
21330
|
+
return _context.abrupt("return", response && Object.seal(new PreauthorizationInstance(_objectSpread2(_objectSpread2({}, response.data), {}, {
|
|
21331
|
+
deviceFingerprint: deviceFingerprint
|
|
21332
|
+
}))));
|
|
21324
21333
|
|
|
21325
|
-
case
|
|
21334
|
+
case 7:
|
|
21326
21335
|
case "end":
|
|
21327
21336
|
return _context.stop();
|
|
21328
21337
|
}
|