cache read without account get from db

This commit is contained in:
crn4
2025-10-02 11:28:59 +02:00
parent 806be13dd5
commit 9a56883ffb
3 changed files with 21 additions and 6 deletions

View File

@@ -19,13 +19,13 @@ func (am *DefaultAccountManager) initNetworkMapBuilderIfNeeded(account *types.Ac
func (am *DefaultAccountManager) getPeerNetworkMapExp(
ctx context.Context,
account *types.Account,
accountId string,
peerId string,
validatedPeers map[string]struct{},
customZone nbdns.CustomZone,
metrics *telemetry.AccountManagerMetrics,
) *types.NetworkMap {
am.enrichAccountFromHolder(account)
account := am.getAccountFromHolder(accountId)
return account.GetPeerNetworkMapExp(ctx, peerId, customZone, validatedPeers, metrics)
}