Skip to content
This repository has been archived by the owner on Nov 15, 2021. It is now read-only.

Commit

Permalink
Fixed bug in Transaction_GetReferences, case issues and missing retur…
Browse files Browse the repository at this point in the history
…n statement
  • Loading branch information
hal0x2328 committed Sep 22, 2017
1 parent 925dc71 commit cca4e93
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions neo/SmartContract/StateReader.py
Original file line number Diff line number Diff line change
Expand Up @@ -166,6 +166,7 @@ def __init__(self):

def Runtime_GetTrigger(self, engine):
engine.EvaluationStack.PushT(engine.Trigger)
return True


def CheckWitnessHash(self, engine, hash):
Expand Down Expand Up @@ -473,7 +474,7 @@ def Transaction_GetInputs(self, engine):
if tx is None:
return False

inputs = [StackItem.FromInterface(input) for input in tx.Inputs]
inputs = [StackItem.FromInterface(input) for input in tx.inputs]
engine.EvaluationStack.PushT(inputs)
return True

Expand All @@ -483,7 +484,7 @@ def Transaction_GetOutputs(self, engine):
if tx is None:
return False

outputs = [StackItem.FromInterface(output) for output in tx.Outputs]
outputs = [StackItem.FromInterface(output) for output in tx.outputs]
engine.EvaluationStack.PushT(outputs)
return True

Expand All @@ -493,7 +494,7 @@ def Transaction_GetReferences(self, engine):
if tx is None:
return False

refs = [StackItem.FromInterface(ref) for ref in tx.References]
refs = [StackItem.FromInterface(tx.References[input]) for input in tx.inputs]
engine.EvaluationStack.PushT(refs)
return True

Expand Down

0 comments on commit cca4e93

Please sign in to comment.