Merge pull request #16 from poanetwork/classic-fix
Fix for support of ETC
This commit is contained in:
commit
4646ec6053
|
@ -15,7 +15,7 @@ const {
|
|||
} = networkIDs
|
||||
|
||||
function getNetworkDisplayName(network) {
|
||||
const netID = isClassic ? network : parseInt(network)
|
||||
const netID = isClassic(network) ? network : parseInt(network)
|
||||
switch (netID) {
|
||||
case MAINNET_CODE:
|
||||
return 'Main Ethereum Network'
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
{
|
||||
"name": "eth-net-props",
|
||||
"version": "1.0.15",
|
||||
"version": "1.0.16",
|
||||
"lockfileVersion": 1,
|
||||
"requires": true,
|
||||
"dependencies": {
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
{
|
||||
"name": "eth-net-props",
|
||||
"version": "1.0.15",
|
||||
"version": "1.0.16",
|
||||
"description": "Get properties of EMV-based network",
|
||||
"main": "index.js",
|
||||
"directories": {
|
||||
|
|
|
@ -279,6 +279,9 @@ describe('eth-net-props', () => {
|
|||
it(`${claimPrefix} Ethereum Classic`, () => {
|
||||
assert.equal(netProps.getNetworkDisplayName('1\''), 'Ethereum Classic')
|
||||
})
|
||||
it(`${claimPrefix} Sokol POA Network`, () => {
|
||||
assert.equal(netProps.getNetworkDisplayName('77'), 'Sokol Test Network')
|
||||
})
|
||||
|
||||
claimPrefix = 'should return correct coin name for'
|
||||
it(`${claimPrefix} Sokol POA Network`, () => {
|
||||
|
|
Loading…
Reference in New Issue