@lucid-evolution/utils 0.1.51 → 0.1.53
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/index.cjs +4 -1
- package/dist/index.js +4 -1
- package/package.json +2 -2
package/dist/index.cjs
CHANGED
|
@@ -353,7 +353,10 @@ function mintingPolicyToId(mintingPolicy) {
|
|
|
353
353
|
return validatorToScriptHash(mintingPolicy);
|
|
354
354
|
}
|
|
355
355
|
function applyParamsToScript(plutusScript, params, type) {
|
|
356
|
-
const program = (0, import_uplc.parseUPLC)(
|
|
356
|
+
const program = (0, import_uplc.parseUPLC)(
|
|
357
|
+
(0, import_cborg2.decode)((0, import_cborg2.decode)((0, import_core_utils2.fromHex)(applyDoubleCborEncoding(plutusScript)))),
|
|
358
|
+
"flat"
|
|
359
|
+
);
|
|
357
360
|
const parameters = type ? import_plutus.Data.castTo(params, type) : params;
|
|
358
361
|
const appliedProgram = parameters.reduce((body, currentParameter) => {
|
|
359
362
|
const data = import_uplc.UPLCConst.data((0, import_plutus_data.dataFromCbor)(import_plutus.Data.to(currentParameter)));
|
package/dist/index.js
CHANGED
|
@@ -267,7 +267,10 @@ function mintingPolicyToId(mintingPolicy) {
|
|
|
267
267
|
return validatorToScriptHash(mintingPolicy);
|
|
268
268
|
}
|
|
269
269
|
function applyParamsToScript(plutusScript, params, type) {
|
|
270
|
-
const program = parseUPLC(
|
|
270
|
+
const program = parseUPLC(
|
|
271
|
+
decode2(decode2(fromHex2(applyDoubleCborEncoding(plutusScript)))),
|
|
272
|
+
"flat"
|
|
273
|
+
);
|
|
271
274
|
const parameters = type ? Data.castTo(params, type) : params;
|
|
272
275
|
const appliedProgram = parameters.reduce((body, currentParameter) => {
|
|
273
276
|
const data = UPLCConst.data(dataFromCbor(Data.to(currentParameter)));
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@lucid-evolution/utils",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.53",
|
|
4
4
|
"description": "",
|
|
5
5
|
"main": "./dist/index.js",
|
|
6
6
|
"types": "./dist/index.d.ts",
|
|
@@ -33,7 +33,7 @@
|
|
|
33
33
|
"@harmoniclabs/uplc": "^1.2.4",
|
|
34
34
|
"bip39": "^3.1.0",
|
|
35
35
|
"cborg": "^4.2.0",
|
|
36
|
-
"effect": "^3.
|
|
36
|
+
"effect": "^3.10.4",
|
|
37
37
|
"@lucid-evolution/core-types": "0.1.21",
|
|
38
38
|
"@lucid-evolution/core-utils": "0.1.16",
|
|
39
39
|
"@lucid-evolution/crc8": "0.1.8",
|