From ff715c8037b599c5d5b4fa30f472ff0c38991830 Mon Sep 17 00:00:00 2001 From: Leonard Lyubich Date: Wed, 19 May 2021 19:00:28 +0300 Subject: [PATCH] [#505] ir/container: Change the way to approve container delete event Call `Delete` method on the wrapper over the Container contract's client directly from `Processor.approveDeleteContainer`. Signed-off-by: Leonard Lyubich --- pkg/innerring/processors/container/process_container.go | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/pkg/innerring/processors/container/process_container.go b/pkg/innerring/processors/container/process_container.go index 75bbce54d..26b4e4fda 100644 --- a/pkg/innerring/processors/container/process_container.go +++ b/pkg/innerring/processors/container/process_container.go @@ -9,10 +9,6 @@ import ( "go.uber.org/zap" ) -const ( - deleteContainerMethod = "delete" -) - // Process new container from the user by checking container sanity // and sending approve tx back to morph. func (cp *Processor) processContainerPut(put *containerEvent.Put) { @@ -87,9 +83,8 @@ func (cp *Processor) checkDeleteContainer(e *containerEvent.Delete) error { } func (cp *Processor) approveDeleteContainer(e *containerEvent.Delete) { - err := cp.morphClient.NotaryInvoke(cp.containerContract, cp.feeProvider.SideChainFee(), deleteContainerMethod, - e.ContainerID(), - e.Signature()) + // FIXME: here we should try notary invoke + err := cp.cnrClient.Delete(e.ContainerID(), e.Signature()) if err != nil { cp.log.Error("could not approve delete container", zap.String("error", err.Error()),