bitcoin.NetworkConstants: easier changing between testnet and mainnet
This commit is contained in:
@@ -9,7 +9,7 @@ from electrum.util import bfh, bh2u
|
||||
from electrum.bitcoin import (is_segwit_address, b58_address_to_hash160, xpub_from_pubkey,
|
||||
public_key_to_p2pkh, EncodeBase58Check,
|
||||
TYPE_ADDRESS, TYPE_SCRIPT,
|
||||
TESTNET, ADDRTYPE_P2PKH, ADDRTYPE_P2SH)
|
||||
NetworkConstants)
|
||||
from electrum.i18n import _
|
||||
from electrum.plugins import BasePlugin, hook
|
||||
from electrum.transaction import deserialize, Transaction
|
||||
@@ -142,7 +142,7 @@ class TrezorCompatiblePlugin(HW_PluginBase):
|
||||
return client
|
||||
|
||||
def get_coin_name(self):
|
||||
return "Testnet" if TESTNET else "Bitcoin"
|
||||
return "Testnet" if NetworkConstants.TESTNET else "Bitcoin"
|
||||
|
||||
def initialize_device(self, device_id, wizard, handler):
|
||||
# Initialization method
|
||||
|
||||
Reference in New Issue
Block a user