improved logging
Some checks failed
ci/woodpecker/push/billing_fees Pipeline was successful
ci/woodpecker/push/bff Pipeline was successful
ci/woodpecker/push/db Pipeline was successful
ci/woodpecker/push/chain_gateway Pipeline was successful
ci/woodpecker/push/fx_ingestor Pipeline was successful
ci/woodpecker/push/frontend Pipeline was successful
ci/woodpecker/push/fx_oracle Pipeline was successful
ci/woodpecker/push/nats Pipeline was successful
ci/woodpecker/push/ledger Pipeline was successful
ci/woodpecker/push/notification Pipeline was successful
ci/woodpecker/push/payments_orchestrator Pipeline was successful
ci/woodpecker/push/bump_version Pipeline failed

This commit is contained in:
Stephan D
2025-11-25 18:30:53 +01:00
parent 85b780b57e
commit d78619bccf
23 changed files with 75 additions and 82 deletions

View File

@@ -147,20 +147,20 @@ func (s *ConfirmationStore) buildRecord(
}
now := time.Now().UTC()
rec := model.NewConfirmationCode(accountRef)
rec.Destination = destination
rec.Target = target
rec.CodeHash = hashCode(salt, code)
rec.Salt = salt
rec.ExpiresAt = now.Add(cfg.TTL)
rec.MaxAttempts = cfg.MaxAttempts
rec.ResendLimit = cfg.ResendLimit
rec.CooldownUntil = now.Add(cfg.Cooldown)
rec.Used = false
rec.Attempts = 0
rec.ResendCount = 0
rec.CreatedAt = now
rec.UpdatedAt = now
rec := &model.ConfirmationCode{
AccountRef: accountRef,
Destination: destination,
Target: target,
CodeHash: hashCode(salt, code),
Salt: salt,
ExpiresAt: now.Add(cfg.TTL),
MaxAttempts: cfg.MaxAttempts,
ResendLimit: cfg.ResendLimit,
CooldownUntil: now.Add(cfg.Cooldown),
Used: false,
Attempts: 0,
ResendCount: 0,
}
return code, salt, rec, nil
}