@ocap/util 1.18.139 → 1.18.141

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.
Files changed (2) hide show
  1. package/lib/index.js +1 -1
  2. package/package.json +2 -2
package/lib/index.js CHANGED
@@ -369,7 +369,7 @@ const toHex = (value, returnType = false) => {
369
369
  return returnType ? 'string' : (0, exports.utf8ToHex)(value);
370
370
  }
371
371
  // eslint-disable-next-line no-nested-ternary
372
- return returnType ? (value < 0 ? 'int256' : 'uint256') : (0, exports.numberToHex)(value);
372
+ return returnType ? (+value < 0 ? 'int256' : 'uint256') : (0, exports.numberToHex)(value);
373
373
  };
374
374
  exports.toHex = toHex;
375
375
  const numberToString = (arg) => {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ocap/util",
3
- "version": "1.18.139",
3
+ "version": "1.18.141",
4
4
  "description": "utils shared across multiple forge js libs, works in both node.js and browser",
5
5
  "keywords": [
6
6
  "arcblock",
@@ -66,5 +66,5 @@
66
66
  "bugs": {
67
67
  "url": "https://github.com/ArcBlock/blockchain/issues"
68
68
  },
69
- "gitHead": "898afef964741ab25b19cc64cc2b6a3ea833b821"
69
+ "gitHead": "b19c6a7fa03932cf37f8a3fbb81a4ced00a2c1a2"
70
70
  }