Browse Source

py3port: Bitcoin ABC v0.18.8.0 compatibility fix

MMGen 6 years ago
parent
commit
fec4fcb772
1 changed files with 3 additions and 1 deletions
  1. 3 1
      mmgen/tx.py

+ 3 - 1
mmgen/tx.py

@@ -86,7 +86,9 @@ def segwit_is_active(exit_on_error=False):
 	d = g.rpch.getblockchaininfo()
 	if d['chain'] == 'regtest':
 		return True
-	if 'segwit' in d['bip9_softforks'] and d['bip9_softforks']['segwit']['status'] == 'active':
+	if (	'bip9_softforks' in d
+			and 'segwit' in d['bip9_softforks']
+			and d['bip9_softforks']['segwit']['status'] == 'active'):
 		return True
 	if g.skip_segwit_active_check:
 		return True