Put api DBs into struct

This commit is contained in:
Arnau B
2020-11-06 11:57:57 +01:00
parent 3591e3c2a2
commit 1112ded933
18 changed files with 172 additions and 172 deletions

View File

@@ -9,7 +9,7 @@ import (
"github.com/hermeznetwork/hermez-node/db/historydb"
)
func getBids(c *gin.Context) {
func (a *API) getBids(c *gin.Context) {
slotNum, bidderAddr, err := parseBidFilters(c)
if err != nil {
retBadReq(err, c)
@@ -26,7 +26,7 @@ func getBids(c *gin.Context) {
return
}
bids, pagination, err := h.GetBidsAPI(
bids, pagination, err := a.h.GetBidsAPI(
slotNum, bidderAddr, fromItem, limit, order,
)