@fuel-ts/account 0.0.0-rc-2021-20240408141516 → 0.0.0-rc-2021-20240409111335
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.
Potentially problematic release.
This version of @fuel-ts/account might be problematic. Click here for more details.
- package/dist/index.global.js +7 -5
- package/dist/index.global.js.map +1 -1
- package/dist/index.js +3 -1
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +3 -1
- package/dist/index.mjs.map +1 -1
- package/dist/test-utils.global.js +7 -5
- package/dist/test-utils.global.js.map +1 -1
- package/dist/test-utils.js +3 -1
- package/dist/test-utils.js.map +1 -1
- package/dist/test-utils.mjs +3 -1
- package/dist/test-utils.mjs.map +1 -1
- package/package.json +16 -16
@@ -35016,7 +35016,7 @@ This unreleased fuel-core build may include features and updates not yet support
|
|
35016
35016
|
var import_bn = __toESM(require_bn(), 1);
|
35017
35017
|
var DEFAULT_PRECISION = 9;
|
35018
35018
|
var DEFAULT_MIN_PRECISION = 3;
|
35019
|
-
var
|
35019
|
+
var DEFAULT_DECIMAL_UNITS = 9;
|
35020
35020
|
function toFixed(value, options) {
|
35021
35021
|
const { precision = DEFAULT_PRECISION, minPrecision = DEFAULT_MIN_PRECISION } = options || {};
|
35022
35022
|
const [valueUnits = "0", valueDecimals = "0"] = String(value || "0.0").split(".");
|
@@ -35082,7 +35082,7 @@ This unreleased fuel-core build may include features and updates not yet support
|
|
35082
35082
|
}
|
35083
35083
|
format(options) {
|
35084
35084
|
const {
|
35085
|
-
units =
|
35085
|
+
units = DEFAULT_DECIMAL_UNITS,
|
35086
35086
|
precision = DEFAULT_PRECISION,
|
35087
35087
|
minPrecision = DEFAULT_MIN_PRECISION
|
35088
35088
|
} = options || {};
|
@@ -35098,7 +35098,7 @@ This unreleased fuel-core build may include features and updates not yet support
|
|
35098
35098
|
}
|
35099
35099
|
return formattedFixed;
|
35100
35100
|
}
|
35101
|
-
formatUnits(units =
|
35101
|
+
formatUnits(units = DEFAULT_DECIMAL_UNITS) {
|
35102
35102
|
const valueUnits = this.toString().slice(0, units * -1);
|
35103
35103
|
const valueDecimals = this.toString().slice(units * -1);
|
35104
35104
|
const length = valueDecimals.length;
|
@@ -35207,7 +35207,7 @@ This unreleased fuel-core build may include features and updates not yet support
|
|
35207
35207
|
// END ANCHOR: OVERRIDES to avoid losing references
|
35208
35208
|
};
|
35209
35209
|
var bn = (value, base, endian) => new BN(value, base, endian);
|
35210
|
-
bn.parseUnits = (value, units =
|
35210
|
+
bn.parseUnits = (value, units = DEFAULT_DECIMAL_UNITS) => {
|
35211
35211
|
const valueToParse = value === "." ? "0." : value;
|
35212
35212
|
const [valueUnits = "0", valueDecimals = "0"] = valueToParse.split(".");
|
35213
35213
|
const length = valueDecimals.length;
|
@@ -42557,7 +42557,9 @@ ${MessageCoinFragmentFragmentDoc}`;
|
|
42557
42557
|
} catch (e) {
|
42558
42558
|
throw new FuelError(
|
42559
42559
|
ErrorCode.STREAM_PARSING_ERROR,
|
42560
|
-
`Error while parsing stream data response: ${text}
|
42560
|
+
`Error while parsing stream data response: ${text}
|
42561
|
+
|
42562
|
+
Thrown error: ${e}`
|
42561
42563
|
);
|
42562
42564
|
}
|
42563
42565
|
if (Array.isArray(errors)) {
|