xrpl 2.1.1 → 2.2.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/build/xrpl-latest-min.js +1 -1
- package/build/xrpl-latest.js +50 -17
- package/dist/npm/Wallet/fundWallet.d.ts +5 -3
- package/dist/npm/Wallet/fundWallet.d.ts.map +1 -1
- package/dist/npm/Wallet/fundWallet.js +7 -7
- package/dist/npm/Wallet/fundWallet.js.map +1 -1
- package/dist/npm/client/BroadcastClient.d.ts.map +1 -1
- package/dist/npm/client/BroadcastClient.js.map +1 -1
- package/dist/npm/client/index.d.ts +4 -1
- package/dist/npm/client/index.d.ts.map +1 -1
- package/dist/npm/client/index.js.map +1 -1
- package/dist/npm/client/partialPayment.d.ts.map +1 -1
- package/dist/npm/client/partialPayment.js +0 -1
- package/dist/npm/client/partialPayment.js.map +1 -1
- package/dist/npm/models/common/index.d.ts +7 -2
- package/dist/npm/models/common/index.d.ts.map +1 -1
- package/dist/npm/models/methods/accountNFTs.d.ts +3 -2
- package/dist/npm/models/methods/accountNFTs.d.ts.map +1 -1
- package/dist/npm/models/methods/accountTx.d.ts +2 -2
- package/dist/npm/models/methods/accountTx.d.ts.map +1 -1
- package/dist/npm/models/methods/federatorInfo.d.ts +64 -0
- package/dist/npm/models/methods/federatorInfo.d.ts.map +1 -0
- package/dist/npm/models/methods/federatorInfo.js +3 -0
- package/dist/npm/models/methods/federatorInfo.js.map +1 -0
- package/dist/npm/models/methods/index.d.ts +4 -3
- package/dist/npm/models/methods/index.d.ts.map +1 -1
- package/dist/npm/models/methods/nftBuyOffers.d.ts +2 -2
- package/dist/npm/models/methods/nftBuyOffers.d.ts.map +1 -1
- package/dist/npm/models/methods/nftSellOffers.d.ts +2 -2
- package/dist/npm/models/methods/nftSellOffers.d.ts.map +1 -1
- package/dist/npm/models/methods/norippleCheck.d.ts +2 -2
- package/dist/npm/models/methods/norippleCheck.d.ts.map +1 -1
- package/dist/npm/models/methods/subscribe.d.ts +6 -3
- package/dist/npm/models/methods/subscribe.d.ts.map +1 -1
- package/dist/npm/models/methods/transactionEntry.d.ts +2 -2
- package/dist/npm/models/methods/transactionEntry.d.ts.map +1 -1
- package/dist/npm/models/methods/tx.d.ts +1 -0
- package/dist/npm/models/methods/tx.d.ts.map +1 -1
- package/dist/npm/models/transactions/NFTokenAcceptOffer.d.ts +3 -3
- package/dist/npm/models/transactions/NFTokenAcceptOffer.d.ts.map +1 -1
- package/dist/npm/models/transactions/NFTokenAcceptOffer.js +10 -10
- package/dist/npm/models/transactions/NFTokenAcceptOffer.js.map +1 -1
- package/dist/npm/models/transactions/NFTokenBurn.d.ts +2 -1
- package/dist/npm/models/transactions/NFTokenBurn.d.ts.map +1 -1
- package/dist/npm/models/transactions/NFTokenBurn.js +2 -2
- package/dist/npm/models/transactions/NFTokenBurn.js.map +1 -1
- package/dist/npm/models/transactions/NFTokenCancelOffer.d.ts +1 -1
- package/dist/npm/models/transactions/NFTokenCancelOffer.d.ts.map +1 -1
- package/dist/npm/models/transactions/NFTokenCancelOffer.js +4 -4
- package/dist/npm/models/transactions/NFTokenCancelOffer.js.map +1 -1
- package/dist/npm/models/transactions/NFTokenCreateOffer.d.ts +3 -3
- package/dist/npm/models/transactions/NFTokenCreateOffer.d.ts.map +1 -1
- package/dist/npm/models/transactions/NFTokenCreateOffer.js +8 -8
- package/dist/npm/models/transactions/NFTokenCreateOffer.js.map +1 -1
- package/dist/npm/models/transactions/NFTokenMint.d.ts +1 -1
- package/dist/npm/models/transactions/NFTokenMint.d.ts.map +1 -1
- package/dist/npm/models/transactions/NFTokenMint.js +2 -2
- package/dist/npm/models/transactions/NFTokenMint.js.map +1 -1
- package/dist/npm/models/transactions/accountSet.d.ts +2 -2
- package/dist/npm/models/transactions/accountSet.d.ts.map +1 -1
- package/dist/npm/models/transactions/accountSet.js +1 -1
- package/dist/npm/models/transactions/accountSet.js.map +1 -1
- package/dist/npm/models/transactions/trustSet.d.ts +2 -2
- package/dist/npm/models/transactions/trustSet.d.ts.map +1 -1
- package/dist/npm/sugar/submit.d.ts.map +1 -1
- package/dist/npm/sugar/submit.js +10 -12
- package/dist/npm/sugar/submit.js.map +1 -1
- package/dist/npm/utils/createCrossChainPayment.d.ts +3 -0
- package/dist/npm/utils/createCrossChainPayment.d.ts.map +1 -0
- package/dist/npm/utils/createCrossChainPayment.js +19 -0
- package/dist/npm/utils/createCrossChainPayment.js.map +1 -0
- package/dist/npm/utils/derive.d.ts +2 -2
- package/dist/npm/utils/derive.d.ts.map +1 -1
- package/dist/npm/utils/derive.js +2 -1
- package/dist/npm/utils/derive.js.map +1 -1
- package/dist/npm/utils/index.d.ts +5 -5
- package/dist/npm/utils/index.d.ts.map +1 -1
- package/dist/npm/utils/index.js +9 -9
- package/dist/npm/utils/index.js.map +1 -1
- package/dist/npm/utils/parseNFTokenID.d.ts +9 -0
- package/dist/npm/utils/parseNFTokenID.d.ts.map +1 -0
- package/dist/npm/utils/parseNFTokenID.js +31 -0
- package/dist/npm/utils/parseNFTokenID.js.map +1 -0
- package/dist/npm/utils/stringConversion.d.ts +5 -0
- package/dist/npm/utils/stringConversion.d.ts.map +1 -0
- package/dist/npm/utils/stringConversion.js +12 -0
- package/dist/npm/utils/stringConversion.js.map +1 -0
- package/package.json +6 -5
package/dist/npm/utils/index.js
CHANGED
@@ -22,7 +22,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
22
22
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
23
23
|
};
|
24
24
|
Object.defineProperty(exports, "__esModule", { value: true });
|
25
|
-
exports.encodeForSigningClaim = exports.encodeForSigning = exports.encodeForMultiSigning = exports.decode = exports.encode = exports.decodeXAddress = exports.encodeXAddress = exports.decodeAccountPublic = exports.encodeAccountPublic = exports.decodeNodePublic = exports.encodeNodePublic = exports.decodeAccountID = exports.encodeAccountID = exports.decodeSeed = exports.encodeSeed = exports.isValidClassicAddress = exports.isValidXAddress = exports.xAddressToClassicAddress = exports.classicAddressToXAddress = exports.convertHexToString = exports.convertStringToHex = exports.verifyPaymentChannelClaim = exports.signPaymentChannelClaim = exports.deriveXAddress = exports.deriveKeypair = exports.hashes = exports.isValidAddress = exports.isValidSecret = exports.qualityToDecimal = exports.transferRateToDecimal = exports.decimalToTransferRate = exports.percentToTransferRate = exports.decimalToQuality = exports.percentToQuality = exports.unixTimeToRippleTime = exports.rippleTimeToUnixTime = exports.isoTimeToRippleTime = exports.rippleTimeToISOTime = exports.hasNextPage = exports.xrpToDrops = exports.dropsToXrp = exports.getBalanceChanges = void 0;
|
25
|
+
exports.parseNFTokenID = exports.createCrossChainPayment = exports.encodeForSigningClaim = exports.encodeForSigning = exports.encodeForMultiSigning = exports.decode = exports.encode = exports.decodeXAddress = exports.encodeXAddress = exports.decodeAccountPublic = exports.encodeAccountPublic = exports.decodeNodePublic = exports.encodeNodePublic = exports.decodeAccountID = exports.encodeAccountID = exports.decodeSeed = exports.encodeSeed = exports.isValidClassicAddress = exports.isValidXAddress = exports.xAddressToClassicAddress = exports.classicAddressToXAddress = exports.convertHexToString = exports.convertStringToHex = exports.verifyPaymentChannelClaim = exports.signPaymentChannelClaim = exports.deriveXAddress = exports.deriveAddress = exports.deriveKeypair = exports.hashes = exports.isValidAddress = exports.isValidSecret = exports.qualityToDecimal = exports.transferRateToDecimal = exports.decimalToTransferRate = exports.percentToTransferRate = exports.decimalToQuality = exports.percentToQuality = exports.unixTimeToRippleTime = exports.rippleTimeToUnixTime = exports.isoTimeToRippleTime = exports.rippleTimeToISOTime = exports.hasNextPage = exports.xrpToDrops = exports.dropsToXrp = exports.getBalanceChanges = void 0;
|
26
26
|
const ripple_address_codec_1 = require("ripple-address-codec");
|
27
27
|
Object.defineProperty(exports, "classicAddressToXAddress", { enumerable: true, get: function () { return ripple_address_codec_1.classicAddressToXAddress; } });
|
28
28
|
Object.defineProperty(exports, "decodeAccountID", { enumerable: true, get: function () { return ripple_address_codec_1.decodeAccountID; } });
|
@@ -39,12 +39,17 @@ Object.defineProperty(exports, "isValidClassicAddress", { enumerable: true, get:
|
|
39
39
|
Object.defineProperty(exports, "isValidXAddress", { enumerable: true, get: function () { return ripple_address_codec_1.isValidXAddress; } });
|
40
40
|
Object.defineProperty(exports, "xAddressToClassicAddress", { enumerable: true, get: function () { return ripple_address_codec_1.xAddressToClassicAddress; } });
|
41
41
|
const rbc = __importStar(require("ripple-binary-codec"));
|
42
|
+
const createCrossChainPayment_1 = __importDefault(require("./createCrossChainPayment"));
|
43
|
+
exports.createCrossChainPayment = createCrossChainPayment_1.default;
|
42
44
|
const derive_1 = require("./derive");
|
43
45
|
Object.defineProperty(exports, "deriveKeypair", { enumerable: true, get: function () { return derive_1.deriveKeypair; } });
|
46
|
+
Object.defineProperty(exports, "deriveAddress", { enumerable: true, get: function () { return derive_1.deriveAddress; } });
|
44
47
|
Object.defineProperty(exports, "deriveXAddress", { enumerable: true, get: function () { return derive_1.deriveXAddress; } });
|
45
48
|
const getBalanceChanges_1 = __importDefault(require("./getBalanceChanges"));
|
46
49
|
exports.getBalanceChanges = getBalanceChanges_1.default;
|
47
50
|
const hashes_1 = require("./hashes");
|
51
|
+
const parseNFTokenID_1 = __importDefault(require("./parseNFTokenID"));
|
52
|
+
exports.parseNFTokenID = parseNFTokenID_1.default;
|
48
53
|
const quality_1 = require("./quality");
|
49
54
|
Object.defineProperty(exports, "percentToTransferRate", { enumerable: true, get: function () { return quality_1.percentToTransferRate; } });
|
50
55
|
Object.defineProperty(exports, "decimalToTransferRate", { enumerable: true, get: function () { return quality_1.decimalToTransferRate; } });
|
@@ -54,6 +59,9 @@ Object.defineProperty(exports, "decimalToQuality", { enumerable: true, get: func
|
|
54
59
|
Object.defineProperty(exports, "qualityToDecimal", { enumerable: true, get: function () { return quality_1.qualityToDecimal; } });
|
55
60
|
const signPaymentChannelClaim_1 = __importDefault(require("./signPaymentChannelClaim"));
|
56
61
|
exports.signPaymentChannelClaim = signPaymentChannelClaim_1.default;
|
62
|
+
const stringConversion_1 = require("./stringConversion");
|
63
|
+
Object.defineProperty(exports, "convertHexToString", { enumerable: true, get: function () { return stringConversion_1.convertHexToString; } });
|
64
|
+
Object.defineProperty(exports, "convertStringToHex", { enumerable: true, get: function () { return stringConversion_1.convertStringToHex; } });
|
57
65
|
const timeConversion_1 = require("./timeConversion");
|
58
66
|
Object.defineProperty(exports, "rippleTimeToISOTime", { enumerable: true, get: function () { return timeConversion_1.rippleTimeToISOTime; } });
|
59
67
|
Object.defineProperty(exports, "isoTimeToRippleTime", { enumerable: true, get: function () { return timeConversion_1.isoTimeToRippleTime; } });
|
@@ -98,14 +106,6 @@ function isValidAddress(address) {
|
|
98
106
|
return (0, ripple_address_codec_1.isValidXAddress)(address) || (0, ripple_address_codec_1.isValidClassicAddress)(address);
|
99
107
|
}
|
100
108
|
exports.isValidAddress = isValidAddress;
|
101
|
-
function convertStringToHex(string) {
|
102
|
-
return Buffer.from(string, 'utf8').toString('hex').toUpperCase();
|
103
|
-
}
|
104
|
-
exports.convertStringToHex = convertStringToHex;
|
105
|
-
function convertHexToString(hex, encoding = 'utf8') {
|
106
|
-
return Buffer.from(hex, 'hex').toString(encoding);
|
107
|
-
}
|
108
|
-
exports.convertHexToString = convertHexToString;
|
109
109
|
function hasNextPage(response) {
|
110
110
|
return Boolean(response.result['marker']);
|
111
111
|
}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/utils/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;AAAA,+DAe6B;
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/utils/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;AAAA,+DAe6B;AAwL3B,yGAtMA,+CAAwB,OAsMA;AAOxB,gGA5MA,sCAAe,OA4MA;AAIf,oGA/MA,0CAAmB,OA+MA;AAFnB,iGA5MA,uCAAgB,OA4MA;AAJhB,2FAvMA,iCAAU,OAuMA;AAQV,+FA9MA,qCA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mBAAU;IACV,gBAAgB,EAAhB,yBAAgB;IAChB,UAAU,EAAV,mBAAU;IACV,kBAAkB,EAAlB,2BAAkB;CACnB,CAAA;AAmBC,wBAAM"}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"parseNFTokenID.d.ts","sourceRoot":"","sources":["../../../src/utils/parseNFTokenID.ts"],"names":[],"mappings":"AAqDA,MAAM,CAAC,OAAO,UAAU,cAAc,CAAC,SAAS,EAAE,MAAM,GAAG;IACzD,SAAS,EAAE,MAAM,CAAA;IACjB,KAAK,EAAE,MAAM,CAAA;IACb,WAAW,EAAE,MAAM,CAAA;IACnB,MAAM,EAAE,MAAM,CAAA;IACd,KAAK,EAAE,MAAM,CAAA;IACb,QAAQ,EAAE,MAAM,CAAA;CACjB,CAuBA"}
|
@@ -0,0 +1,31 @@
|
|
1
|
+
"use strict";
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
4
|
+
};
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
6
|
+
const bignumber_js_1 = __importDefault(require("bignumber.js"));
|
7
|
+
const ripple_address_codec_1 = require("ripple-address-codec");
|
8
|
+
const errors_1 = require("../errors");
|
9
|
+
function unscrambleTaxon(taxon, tokenSeq) {
|
10
|
+
return (taxon ^ (384160001 * tokenSeq + 2459)) % 4294967296;
|
11
|
+
}
|
12
|
+
function parseNFTokenID(nftokenID) {
|
13
|
+
const expectedLength = 64;
|
14
|
+
if (nftokenID.length !== expectedLength) {
|
15
|
+
throw new errors_1.XrplError(`Attempting to parse a nftokenID with length ${nftokenID.length}
|
16
|
+
, but expected a token with length ${expectedLength}`);
|
17
|
+
}
|
18
|
+
const scrambledTaxon = new bignumber_js_1.default(nftokenID.substring(48, 56), 16).toNumber();
|
19
|
+
const sequence = new bignumber_js_1.default(nftokenID.substring(56, 64), 16).toNumber();
|
20
|
+
const NFTokenIDData = {
|
21
|
+
NFTokenID: nftokenID,
|
22
|
+
Flags: new bignumber_js_1.default(nftokenID.substring(0, 4), 16).toNumber(),
|
23
|
+
TransferFee: new bignumber_js_1.default(nftokenID.substring(4, 8), 16).toNumber(),
|
24
|
+
Issuer: (0, ripple_address_codec_1.encodeAccountID)(Buffer.from(nftokenID.substring(8, 48), 'hex')),
|
25
|
+
Taxon: unscrambleTaxon(scrambledTaxon, sequence),
|
26
|
+
Sequence: sequence,
|
27
|
+
};
|
28
|
+
return NFTokenIDData;
|
29
|
+
}
|
30
|
+
exports.default = parseNFTokenID;
|
31
|
+
//# sourceMappingURL=parseNFTokenID.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"parseNFTokenID.js","sourceRoot":"","sources":["../../../src/utils/parseNFTokenID.ts"],"names":[],"mappings":";;;;;AACA,gEAAoC;AACpC,+DAAsD;AAEtD,sCAAqC;AAoBrC,SAAS,eAAe,CAAC,KAAa,EAAE,QAAgB;IAEtD,OAAO,CAAC,KAAK,GAAG,CAAC,SAAS,GAAG,QAAQ,GAAG,IAAI,CAAC,CAAC,GAAG,UAAU,CAAA;AAE7D,CAAC;AAyBD,SAAwB,cAAc,CAAC,SAAiB;IAQtD,MAAM,cAAc,GAAG,EAAE,CAAA;IACzB,IAAI,SAAS,CAAC,MAAM,KAAK,cAAc,EAAE;QACvC,MAAM,IAAI,kBAAS,CAAC,+CAA+C,SAAS,CAAC,MAAM;yCAC9C,cAAc,EAAE,CAAC,CAAA;KACvD;IAED,MAAM,cAAc,GAAG,IAAI,sBAAS,CAClC,SAAS,CAAC,SAAS,CAAC,EAAE,EAAE,EAAE,CAAC,EAC3B,EAAE,CACH,CAAC,QAAQ,EAAE,CAAA;IACZ,MAAM,QAAQ,GAAG,IAAI,sBAAS,CAAC,SAAS,CAAC,SAAS,CAAC,EAAE,EAAE,EAAE,CAAC,EAAE,EAAE,CAAC,CAAC,QAAQ,EAAE,CAAA;IAE1E,MAAM,aAAa,GAAG;QACpB,SAAS,EAAE,SAAS;QACpB,KAAK,EAAE,IAAI,sBAAS,CAAC,SAAS,CAAC,SAAS,CAAC,CAAC,EAAE,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,QAAQ,EAAE;QAC9D,WAAW,EAAE,IAAI,sBAAS,CAAC,SAAS,CAAC,SAAS,CAAC,CAAC,EAAE,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,QAAQ,EAAE;QACpE,MAAM,EAAE,IAAA,sCAAe,EAAC,MAAM,CAAC,IAAI,CAAC,SAAS,CAAC,SAAS,CAAC,CAAC,EAAE,EAAE,CAAC,EAAE,KAAK,CAAC,CAAC;QACvE,KAAK,EAAE,eAAe,CAAC,cAAc,EAAE,QAAQ,CAAC;QAChD,QAAQ,EAAE,QAAQ;KACnB,CAAA;IAED,OAAO,aAAa,CAAA;AACtB,CAAC;AA9BD,iCA8BC"}
|
@@ -0,0 +1,5 @@
|
|
1
|
+
/// <reference types="node" />
|
2
|
+
declare function convertStringToHex(string: string): string;
|
3
|
+
declare function convertHexToString(hex: string, encoding?: BufferEncoding): string;
|
4
|
+
export { convertHexToString, convertStringToHex };
|
5
|
+
//# sourceMappingURL=stringConversion.d.ts.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"stringConversion.d.ts","sourceRoot":"","sources":["../../../src/utils/stringConversion.ts"],"names":[],"mappings":";AAOA,iBAAS,kBAAkB,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,CAElD;AAUD,iBAAS,kBAAkB,CACzB,GAAG,EAAE,MAAM,EACX,QAAQ,GAAE,cAAuB,GAChC,MAAM,CAER;AAED,OAAO,EAAE,kBAAkB,EAAE,kBAAkB,EAAE,CAAA"}
|
@@ -0,0 +1,12 @@
|
|
1
|
+
"use strict";
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
+
exports.convertStringToHex = exports.convertHexToString = void 0;
|
4
|
+
function convertStringToHex(string) {
|
5
|
+
return Buffer.from(string, 'utf8').toString('hex').toUpperCase();
|
6
|
+
}
|
7
|
+
exports.convertStringToHex = convertStringToHex;
|
8
|
+
function convertHexToString(hex, encoding = 'utf8') {
|
9
|
+
return Buffer.from(hex, 'hex').toString(encoding);
|
10
|
+
}
|
11
|
+
exports.convertHexToString = convertHexToString;
|
12
|
+
//# sourceMappingURL=stringConversion.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"stringConversion.js","sourceRoot":"","sources":["../../../src/utils/stringConversion.ts"],"names":[],"mappings":";;;AAOA,SAAS,kBAAkB,CAAC,MAAc;IACxC,OAAO,MAAM,CAAC,IAAI,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC,QAAQ,CAAC,KAAK,CAAC,CAAC,WAAW,EAAE,CAAA;AAClE,CAAC;AAiB4B,gDAAkB;AAP/C,SAAS,kBAAkB,CACzB,GAAW,EACX,WAA2B,MAAM;IAEjC,OAAO,MAAM,CAAC,IAAI,CAAC,GAAG,EAAE,KAAK,CAAC,CAAC,QAAQ,CAAC,QAAQ,CAAC,CAAA;AACnD,CAAC;AAEQ,gDAAkB"}
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "xrpl",
|
3
|
-
"version": "2.
|
3
|
+
"version": "2.2.2",
|
4
4
|
"license": "ISC",
|
5
5
|
"description": "A TypeScript/JavaScript API for interacting with the XRP Ledger in Node.js and the browser",
|
6
6
|
"files": [
|
@@ -24,9 +24,9 @@
|
|
24
24
|
"bip39": "^3.0.4",
|
25
25
|
"https-proxy-agent": "^5.0.0",
|
26
26
|
"lodash": "^4.17.4",
|
27
|
-
"ripple-address-codec": "^4.2.
|
28
|
-
"ripple-binary-codec": "^1.
|
29
|
-
"ripple-keypairs": "^1.1.
|
27
|
+
"ripple-address-codec": "^4.2.4",
|
28
|
+
"ripple-binary-codec": "^1.4.0",
|
29
|
+
"ripple-keypairs": "^1.1.4",
|
30
30
|
"ws": "^8.2.2"
|
31
31
|
},
|
32
32
|
"devDependencies": {
|
@@ -65,5 +65,6 @@
|
|
65
65
|
"readmeFilename": "README.md",
|
66
66
|
"engines": {
|
67
67
|
"node": ">=10.13.0"
|
68
|
-
}
|
68
|
+
},
|
69
|
+
"gitHead": "6d3b2d3a9e2ebcf68cd90cdb10d4e4a7c9d73004"
|
69
70
|
}
|