ethereumjs-util
Advanced tools
Comparing version 2.0.1 to 2.0.2
@@ -245,3 +245,3 @@ const SHA3 = require('sha3') | ||
} | ||
return exports.isHexPrefixed(str) ? '0x' + str : str | ||
return exports.isHexPrefixed(str) ? str : '0x' + str | ||
} | ||
@@ -248,0 +248,0 @@ |
{ | ||
"name": "ethereumjs-util", | ||
"version": "2.0.1", | ||
"version": "2.0.2", | ||
"description": "a collection of utility functions for Ethereum", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
@@ -11,3 +11,3 @@ var assert = require('assert') | ||
name: 'empty', | ||
empty: true, | ||
allowZero: true, | ||
length: 20, | ||
@@ -17,5 +17,2 @@ default: new Buffer([]) | ||
name: 'value', | ||
empty: true, | ||
word: true, | ||
noZero: true, | ||
default: new Buffer([]) | ||
@@ -22,0 +19,0 @@ }, { |
@@ -132,1 +132,8 @@ var assert = require('assert') | ||
}) | ||
describe('hex prefix', function () { | ||
var string = 'd658a4b8247c14868f3c512fa5cbb6e458e4a989' | ||
it(' should add', function () { | ||
assert.equal(ethUtils.addHexPrefix(string), '0x' + string) | ||
}) | ||
}) |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
57356
490