@0xcert/ethereum-utils
Advanced tools
Comparing version 0.0.0-alpha8 to 0.0.0-alpha9
@@ -1,1 +0,1 @@ | ||
export declare function normalizeAddress(address: any): any; | ||
export declare function normalizeAddress(address: string): any; |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
const address_1 = require("ethers/utils/address"); | ||
function normalizeAddress(address) { | ||
if (!address) { | ||
return address; | ||
} | ||
else { | ||
return address.toLowerCase(); | ||
} | ||
return address_1.getAddress(address); | ||
} | ||
exports.normalizeAddress = normalizeAddress; | ||
//# sourceMappingURL=normalize-address.js.map |
{ | ||
"files": { | ||
"packages/0xcert-ethereum-utils/README.md": "a4f7b69c2c6dd7a7b42f18d4b54c6c47d39d116e", | ||
"packages/0xcert-ethereum-utils/nodemon.json": "82b893373db9861f1df4b55d8ea68a5d37b118de", | ||
"packages/0xcert-ethereum-utils/package.json": "6ae37b4ec0eba232df32ee7608c4df434ee204f9", | ||
"packages/0xcert-ethereum-utils/src/index.ts": "7572a5bccc32fd2d321a3e80ed303e6a944d0f08", | ||
"packages/0xcert-ethereum-utils/src/lib/abi.ts": "9c257bbbc44db4b4495f02ec8f7b8453754779a5", | ||
"packages/0xcert-ethereum-utils/src/lib/big-number.ts": "12fe3d0e7d721fd0beb939467104cdc4c99bef09", | ||
"packages/0xcert-ethereum-utils/src/lib/normalize-address.ts": "298f0d0dfd374ef8039ed334614be4a82923d0d3", | ||
"packages/0xcert-ethereum-utils/src/tests/encode-parameters.test.ts": "e8c7395cea9868d1dc97bf60b80bf85adfe15b91", | ||
"packages/0xcert-ethereum-utils/src/tests/index.test.ts": "4158bc2c5b392389a4edcfd938158a0acad3a9e2", | ||
"packages/0xcert-ethereum-utils/tsconfig.json": "4aeac3c20e45b7e477e82012eb7788f7dbb11bf3", | ||
"common/config/rush/npm-shrinkwrap.json": "8f19ba9dbdefd16dc6af9aff055b174191c3e0b8" | ||
}, | ||
"files": {}, | ||
"arguments": "npx specron test " | ||
} |
{ | ||
"name": "@0xcert/ethereum-utils", | ||
"version": "0.0.0-alpha8", | ||
"version": "0.0.0-alpha9", | ||
"description": "General Ethereum utility module with helper functions for the Ethereum blockchain.", | ||
@@ -58,3 +58,3 @@ "main": "./dist/index.js", | ||
"devDependencies": { | ||
"@0xcert/ethereum-sandbox": "0.0.0-alpha8", | ||
"@0xcert/ethereum-sandbox": "0.0.0-alpha9", | ||
"@specron/cli": "^0.5.1", | ||
@@ -66,3 +66,3 @@ "@specron/spec": "^0.5.1", | ||
"web3": "^1.0.0-beta.36", | ||
"@0xcert/utils": "0.0.0-alpha8" | ||
"@0xcert/utils": "0.0.0-alpha9" | ||
}, | ||
@@ -69,0 +69,0 @@ "dependencies": { |
@@ -0,1 +1,3 @@ | ||
import { getAddress } from 'ethers/utils/address'; | ||
/** | ||
@@ -5,9 +7,4 @@ * | ||
*/ | ||
export function normalizeAddress(address) { | ||
if (!address) { | ||
return address; | ||
} | ||
else { | ||
return address.toLowerCase(); | ||
} | ||
export function normalizeAddress(address: string) { | ||
return getAddress(address); | ||
} |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
10789
34
135