diff --git a/src/address.js b/src/address.js index 354dda8..9a010dd 100644 --- a/src/address.js +++ b/src/address.js @@ -1,7 +1,6 @@ var base58 = require('./base58') var base58check = require('./base58check') var convert = require('./convert') -var error = require('./util').error var mainnet = require('./network').mainnet.addressVersion function Address(bytes, version) { @@ -25,7 +24,7 @@ function Address(bytes, version) { this.version = version || mainnet } else { - error('invalid or unrecognized input') + throw new Error('Invalid or unrecognized input') } } else { diff --git a/src/util.js b/src/util.js index 9cbc541..6ec6d15 100644 --- a/src/util.js +++ b/src/util.js @@ -7,7 +7,3 @@ exports.sha256ripe160 = function (data) { var wordArray = RIPEMD160(SHA256(convert.bytesToWordArray(data))) return convert.wordArrayToBytes(wordArray) } - -exports.error = function (msg) { - throw new Error(msg) -}