Added a notion of current transaction
Fixing the checks for transaction contracts