fix decode segwit outputs for non segwit transactions

This commit is contained in:
4tochka 2018-09-29 13:46:50 +04:00
parent b76d4122d6
commit 60e112b299

View File

@ -77,7 +77,7 @@ class Transaction(dict):
self["vOut"][k]["value"] = unpack('<Q', stream.read(8))[0]
self["amount"] += self["vOut"][k]["value"]
self["vOut"][k]["scriptPubKey"] = stream.read(var_int_to_int(read_var_int(stream)))
s = parse_script(self["vOut"][k]["scriptPubKey"], sw)
s = parse_script(self["vOut"][k]["scriptPubKey"])
self["vOut"][k]["nType"] = s["nType"]
self["vOut"][k]["type"] = s["type"]
if self["data"] is None: