From 313bb0c2b3e7f21b5c918ec34fafdcc658233ff8 Mon Sep 17 00:00:00 2001 From: Christian Rinderknecht Date: Wed, 4 Mar 2020 15:23:51 +0100 Subject: [PATCH] Reverted two changes. --- src/test/contracts/entrypoints.ligo | 6 +----- src/test/contracts/get_contract.ligo | 6 +----- 2 files changed, 2 insertions(+), 10 deletions(-) diff --git a/src/test/contracts/entrypoints.ligo b/src/test/contracts/entrypoints.ligo index d47a8b78a..8775e7314 100644 --- a/src/test/contracts/entrypoints.ligo +++ b/src/test/contracts/entrypoints.ligo @@ -4,11 +4,7 @@ type return is list (operation) * storage function cb (const a : address; const s : storage) : return is block { - const c : contract (unit) = - case (Tezos.get_entrypoint_opt ("%cb", a) : option (contract (unit))) of - Some (contract) -> contract - | None -> (failwith ("cb: Entrypoint not found.") : contract (unit)) - end + const c : contract (unit) = get_entrypoint ("%cb", a) } with (list [Tezos.transaction (unit, 0tez, c)], s) diff --git a/src/test/contracts/get_contract.ligo b/src/test/contracts/get_contract.ligo index 5a7ca3541..13d325cba 100644 --- a/src/test/contracts/get_contract.ligo +++ b/src/test/contracts/get_contract.ligo @@ -2,11 +2,7 @@ type storage is unit type return is list (operation) * storage function cb (const s : storage) : return is block { - const c : contract (unit) = - case (Tezos.get_contract_opt (Tezos.sender) : option (contract (unit))) of - Some (contract) -> contract - | None -> (failwith ("cb: No contract.") : contract (unit)) - end + const c : contract (unit) = get_contract (Tezos.sender) } with (list [Tezos.transaction (unit, 0tez, c)], s)