Skip to content

Commit

Permalink
The coin name is Firo now
Browse files Browse the repository at this point in the history
  • Loading branch information
a-bezrukov committed May 14, 2021
1 parent 56ae288 commit a79f455
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions electrum_dash/plugins/trezor/trezor.py
Original file line number Diff line number Diff line change
Expand Up @@ -206,7 +206,10 @@ def get_client(self, keystore, force_pair=True, *,
client.used()
return client

def get_coin_name(self):
def get_coin_name(self, version):
if (version[0] == 1 and version[1] < 10) \
or (version[0] == 2 and version[1] <= 3 and version[2] <= 6):
return "Zcoin Testnet" if constants.net.TESTNET else "Zcoin"
return "Firo Testnet" if constants.net.TESTNET else "Firo"

def initialize_device(self, device_id, wizard, handler):
Expand Down Expand Up @@ -339,7 +342,7 @@ def sign_transaction(self, keystore, tx: PartialTransaction, prev_tx):
inputs = self.tx_inputs(tx, for_sig=True, keystore=keystore)
outputs = self.tx_outputs(tx, keystore=keystore)
details = SignTx(lock_time=tx.locktime, version=tx.version)
signatures, _ = client.sign_tx(self.get_coin_name(), inputs, outputs, details=details, prev_txes=prev_tx)
signatures, _ = client.sign_tx(self.get_coin_name(client.client.version), inputs, outputs, details=details, prev_txes=prev_tx)
signatures = [(bh2u(x) + '01') for x in signatures]
tx.update_signatures(signatures)

Expand Down

0 comments on commit a79f455

Please sign in to comment.