fix(lib): make tests pass

Signed-off-by: Xe Iaso <me@xeiaso.net>
This commit is contained in:
Xe Iaso
2025-08-04 17:30:35 +00:00
parent 02fc1079cc
commit cbf5c2c772
5 changed files with 77 additions and 5 deletions

View File

@@ -369,9 +369,11 @@ func (s *Server) MakeChallenge(w http.ResponseWriter, r *http.Request) {
err = encoder.Encode(struct {
Rules *config.ChallengeRules `json:"rules"`
Challenge string `json:"challenge"`
ID string `json:"id"`
}{
Challenge: chall.RandomData,
Rules: rule.Challenge,
Challenge: chall.RandomData,
ID: chall.ID,
})
if err != nil {
lg.Error("failed to encode challenge", "err", err)