Skip to content

Commit

Permalink
Heartbeat should be a single word in language/types throughout indexer.
Browse files Browse the repository at this point in the history
  • Loading branch information
gmalouf committed Dec 10, 2024
1 parent 0d8ea57 commit d978ad2
Show file tree
Hide file tree
Showing 9 changed files with 169 additions and 171 deletions.
14 changes: 7 additions & 7 deletions api/converter_utils.go
Original file line number Diff line number Diff line change
Expand Up @@ -306,7 +306,7 @@ func signedTxnWithAdToTransaction(stxn *sdk.SignedTxnWithAD, extra rowData) (gen
var assetTransfer *generated.TransactionAssetTransfer
var application *generated.TransactionApplication
var stateProof *generated.TransactionStateProof
var heartbeat *generated.TransactionHeartBeat
var heartbeat *generated.TransactionHeartbeat

switch stxn.Txn.Type {
case sdk.PaymentTx:
Expand Down Expand Up @@ -512,7 +512,7 @@ func signedTxnWithAdToTransaction(stxn *sdk.SignedTxnWithAD, extra rowData) (gen
stateProof = &proofTxn
case sdk.HeartbeatTx:
hb := stxn.Txn.HeartbeatTxnFields
hbTxn := generated.TransactionHeartBeat{
hbTxn := generated.TransactionHeartbeat{
HbAddress: hb.HbAddress.String(),
HbProof: generated.HbProofFields{
HbPk: byteSliceOmitZeroPtr(hb.HbProof.PK[:]),
Expand Down Expand Up @@ -574,9 +574,9 @@ func signedTxnWithAdToTransaction(stxn *sdk.SignedTxnWithAD, extra rowData) (gen
for _, t := range stxn.ApplyData.EvalDelta.InnerTxns {
extra2 := extra
if t.Txn.Type == sdk.ApplicationCallTx {
extra2.AssetID = uint64(t.ApplyData.ApplicationID)
extra2.AssetID = t.ApplyData.ApplicationID
} else if t.Txn.Type == sdk.AssetConfigTx {
extra2.AssetID = uint64(t.ApplyData.ConfigAsset)
extra2.AssetID = t.ApplyData.ConfigAsset
} else {
extra2.AssetID = 0
}
Expand All @@ -600,7 +600,7 @@ func signedTxnWithAdToTransaction(stxn *sdk.SignedTxnWithAD, extra rowData) (gen
PaymentTransaction: payment,
KeyregTransaction: keyreg,
StateProofTransaction: stateProof,
HeartBeatTransaction: heartbeat,
HeartbeatTransaction: heartbeat,
ClosingAmount: uint64Ptr(uint64(stxn.ClosingAmount)),
ConfirmedRound: uint64Ptr(extra.Round),
IntraRoundOffset: uint64Ptr(uint64(extra.Intra)),
Expand Down Expand Up @@ -767,9 +767,9 @@ func (si *ServerImplementation) transactionParamsToTransactionFilter(params gene

func (si *ServerImplementation) maxAccountsErrorToAccountsErrorResponse(maxErr idb.MaxAPIResourcesPerAccountError) generated.ErrorResponse {
addr := maxErr.Address.String()
max := uint64(si.opts.MaxAPIResourcesPerAccount)
maxResults := si.opts.MaxAPIResourcesPerAccount
extraData := map[string]interface{}{
"max-results": max,
"max-results": maxResults,
"address": addr,
"total-assets-opted-in": maxErr.TotalAssets,
"total-created-assets": maxErr.TotalAssetParams,
Expand Down
96 changes: 48 additions & 48 deletions api/generated/common/routes.go

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

16 changes: 8 additions & 8 deletions api/generated/common/types.go

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

Loading

0 comments on commit d978ad2

Please sign in to comment.