From e2a18b40a067eeab69483221b69817df2ab66f87 Mon Sep 17 00:00:00 2001 From: p4u Date: Tue, 28 Nov 2023 16:08:45 +0100 Subject: [PATCH] fix get archive entity from indexer with 0x prefix Signed-off-by: p4u --- api/accounts.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/api/accounts.go b/api/accounts.go index 62bd78ca0..b25f8e8f3 100644 --- a/api/accounts.go +++ b/api/accounts.go @@ -135,7 +135,7 @@ func (a *API) accountHandler(_ *apirest.APIdata, ctx *httprouter.HTTPContext) er // If the account does not exist in state, try to retrieve it from the indexer. // This is a fallback for the case where the account is not in state but it is in the process archive. if acc == nil { - indexerEntities := a.indexer.EntityList(1, 0, ctx.URLParam("address")) + indexerEntities := a.indexer.EntityList(1, 0, hex.EncodeToString(addr.Bytes())) if len(indexerEntities) == 0 { return ErrAccountNotFound.With(addr.Hex()) }