diff --git a/mapper/transaction.go b/mapper/transaction.go index 927cb4c3..9095ccc8 100644 --- a/mapper/transaction.go +++ b/mapper/transaction.go @@ -154,7 +154,7 @@ func crossChainTransaction( continue } - op := &types.Operation{ + ops = append(ops, &types.Operation{ OperationIdentifier: &types.OperationIdentifier{ Index: int64(idx), }, @@ -176,8 +176,7 @@ func crossChainTransaction( "meta": t.Metadata, "asset_id": out.AssetID.String(), }, - } - ops = append(ops, op) + }) } case *evm.UnsignedExportTx: for idx, in := range t.Ins { @@ -185,7 +184,7 @@ func crossChainTransaction( continue } - op := &types.Operation{ + ops = append(ops, &types.Operation{ OperationIdentifier: &types.OperationIdentifier{ Index: int64(idx), }, @@ -206,8 +205,7 @@ func crossChainTransaction( "meta": t.Metadata, "asset_id": in.AssetID.String(), }, - } - ops = append(ops, op) + }) } default: return nil, fmt.Errorf("unsupported transaction: %T", t)