Skip to content

Commit

Permalink
nit
Browse files Browse the repository at this point in the history
  • Loading branch information
dhrubabasu committed Feb 4, 2022
1 parent 72e98b0 commit aa03b2b
Showing 1 changed file with 4 additions and 6 deletions.
10 changes: 4 additions & 6 deletions mapper/transaction.go
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,7 @@ func crossChainTransaction(
continue
}

op := &types.Operation{
ops = append(ops, &types.Operation{
OperationIdentifier: &types.OperationIdentifier{
Index: int64(idx),
},
Expand All @@ -176,16 +176,15 @@ func crossChainTransaction(
"meta": t.Metadata,
"asset_id": out.AssetID.String(),
},
}
ops = append(ops, op)
})
}
case *evm.UnsignedExportTx:
for idx, in := range t.Ins {
if in.AssetID.String() != avaxAssetID {
continue
}

op := &types.Operation{
ops = append(ops, &types.Operation{
OperationIdentifier: &types.OperationIdentifier{
Index: int64(idx),
},
Expand All @@ -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)
Expand Down

0 comments on commit aa03b2b

Please sign in to comment.