From c7c8edd982beecfea574bba3c2cd8ecb8ff3b67b Mon Sep 17 00:00:00 2001 From: kim Date: Tue, 22 Apr 2025 19:57:38 +0100 Subject: [PATCH] formatting --- internal/middleware/nollamas.go | 6 +++--- web/template/nollamas.tmpl | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/internal/middleware/nollamas.go b/internal/middleware/nollamas.go index f15fb7f38..fc7a24716 100644 --- a/internal/middleware/nollamas.go +++ b/internal/middleware/nollamas.go @@ -125,7 +125,7 @@ func (m *nollamas) Serve(c *gin.Context) { nonce := query.Get("nollamas_solution") if nonce == "" || len(nonce) > 20 { - // No attempted solution, just + // An invalid solution string, just // present them with new challenge. m.renderChallenge(c, challenge) return @@ -190,8 +190,8 @@ func (m *nollamas) token(c *gin.Context, hash hash.Hash) string { _, _ = hash.Write([]byte{m.diff}) // Also seed the generated input with - // current time rounded to TTL, so with - // our single comparison handles expiries. + // current time rounded to TTL, so our + // single comparison handles expiries. now := time.Now().Round(m.ttl).Unix() _, _ = hash.Write([]byte{ byte(now >> 56), diff --git a/web/template/nollamas.tmpl b/web/template/nollamas.tmpl index db4d66400..faaf70054 100644 --- a/web/template/nollamas.tmpl +++ b/web/template/nollamas.tmpl @@ -64,10 +64,10 @@ console.log('difficulty:', difficulty); // Prepare the worker with task function. - const worker = new Worker(workerTaskURL); + const worker = new Worker(workerTaskURL); worker.postMessage({ - challenge: challenge, - difficulty: difficulty, + challenge: challenge, + difficulty: difficulty, }); // Set the main worker function.