Skip to content

Commit

Permalink
stellar#4728: fix gofmt warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
sreuland committed Mar 17, 2023
1 parent e658d34 commit 5b6ae34
Show file tree
Hide file tree
Showing 4 changed files with 25 additions and 16 deletions.
8 changes: 6 additions & 2 deletions protocols/horizon/operations/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -375,10 +375,14 @@ type HostFunctionParameter struct {
}

// Type - refers to the source SAC Event
// it can only be one of 'transfer', 'mint', 'clawback' or 'burn'
//
// it can only be one of 'transfer', 'mint', 'clawback' or 'burn'
//
// From - this is classic account that asset balance was changed.
// To - this is the classic account that asset balance was changed, or if not applicable
// for asset contract event type, it can be absent such as 'burn'
//
// for asset contract event type, it can be absent such as 'burn'
//
// Amount - expressed as a signed decimal to 7 digits precision.
// Asset - the classic asset expressed as issuer and code.
type AssetContractBalanceChange struct {
Expand Down
12 changes: 7 additions & 5 deletions services/horizon/internal/db2/schema/bindata.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -714,13 +714,14 @@ func (operation *transactionOperationWrapper) Details() (map[string]interface{},
// then it will be skipped and not ingested as a balance change into the operation details.
//
// SAC events have a one-to-one association to SAC contract fn invocations,
// i.e. invoke the 'mint' function, will trigger one Mint Event to be emitted capturing the fn args.
//
// i.e. invoke the 'mint' function, will trigger one Mint Event to be emitted capturing the fn args.
//
// SAC events that involve asset balance changes follow some standard data formats:
// The 'amount' in the event is expressed as Int128Parts, which carries a sign, however it's expected
// that value will not be signed as it represents a absolute delta, the event type can provide the
// context of whether an amount was considered incremental or decremental, i.e. credit or debit to a balance.
//
// The 'amount' in the event is expressed as Int128Parts, which carries a sign, however it's expected
// that value will not be signed as it represents a absolute delta, the event type can provide the
// context of whether an amount was considered incremental or decremental, i.e. credit or debit to a balance.
func (operation *transactionOperationWrapper) parseAssetBalanceChangesFromContractEvents() ([]map[string]interface{}, error) {
balanceChanges := []map[string]interface{}{}

Expand Down
12 changes: 7 additions & 5 deletions services/horizon/internal/test/scenarios/bindata.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 5b6ae34

Please sign in to comment.