aboutsummaryrefslogtreecommitdiffstats
path: root/internal
diff options
context:
space:
mode:
Diffstat (limited to 'internal')
-rw-r--r--internal/ethapi/api.go16
1 files changed, 8 insertions, 8 deletions
diff --git a/internal/ethapi/api.go b/internal/ethapi/api.go
index 371786e4a..c4a871e48 100644
--- a/internal/ethapi/api.go
+++ b/internal/ethapi/api.go
@@ -117,16 +117,16 @@ func (s *PublicTxPoolAPI) Content() map[string]map[string]map[string]*RPCTransac
// Flatten the pending transactions
for account, txs := range pending {
dump := make(map[string]*RPCTransaction)
- for nonce, tx := range txs {
- dump[fmt.Sprintf("%d", nonce)] = newRPCPendingTransaction(tx)
+ for _, tx := range txs {
+ dump[fmt.Sprintf("%d", tx.Nonce())] = newRPCPendingTransaction(tx)
}
content["pending"][account.Hex()] = dump
}
// Flatten the queued transactions
for account, txs := range queue {
dump := make(map[string]*RPCTransaction)
- for nonce, tx := range txs {
- dump[fmt.Sprintf("%d", nonce)] = newRPCPendingTransaction(tx)
+ for _, tx := range txs {
+ dump[fmt.Sprintf("%d", tx.Nonce())] = newRPCPendingTransaction(tx)
}
content["queued"][account.Hex()] = dump
}
@@ -161,16 +161,16 @@ func (s *PublicTxPoolAPI) Inspect() map[string]map[string]map[string]string {
// Flatten the pending transactions
for account, txs := range pending {
dump := make(map[string]string)
- for nonce, tx := range txs {
- dump[fmt.Sprintf("%d", nonce)] = format(tx)
+ for _, tx := range txs {
+ dump[fmt.Sprintf("%d", tx.Nonce())] = format(tx)
}
content["pending"][account.Hex()] = dump
}
// Flatten the queued transactions
for account, txs := range queue {
dump := make(map[string]string)
- for nonce, tx := range txs {
- dump[fmt.Sprintf("%d", nonce)] = format(tx)
+ for _, tx := range txs {
+ dump[fmt.Sprintf("%d", tx.Nonce())] = format(tx)
}
content["queued"][account.Hex()] = dump
}