summaryrefslogtreecommitdiff
path: root/srv/api/pow.go
diff options
context:
space:
mode:
authorBrian Picciano <mediocregopher@gmail.com>2021-09-02 17:02:20 -0600
committerBrian Picciano <mediocregopher@gmail.com>2021-09-02 17:02:20 -0600
commit34f44cb5d5d6316009f242d27d2f3d69f4d5b90e (patch)
tree116a6e2db06dac246e794d1bc7f9e8b0c04f22e9 /srv/api/pow.go
parent6bebc3fae73b5f5f68e5de9e083635cfab9037b1 (diff)
implementation of basic chat page which can show history and not much else
Diffstat (limited to 'srv/api/pow.go')
-rw-r--r--srv/api/pow.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/srv/api/pow.go b/srv/api/pow.go
index 6d11061..1b232b1 100644
--- a/srv/api/pow.go
+++ b/srv/api/pow.go
@@ -27,14 +27,14 @@ func (a *api) newPowChallengeHandler() http.Handler {
func (a *api) requirePowMiddleware(h http.Handler) http.Handler {
return http.HandlerFunc(func(rw http.ResponseWriter, r *http.Request) {
- seedHex := r.PostFormValue("powSeed")
+ seedHex := r.FormValue("powSeed")
seed, err := hex.DecodeString(seedHex)
if err != nil || len(seed) == 0 {
apiutils.BadRequest(rw, r, errors.New("invalid powSeed"))
return
}
- solutionHex := r.PostFormValue("powSolution")
+ solutionHex := r.FormValue("powSolution")
solution, err := hex.DecodeString(solutionHex)
if err != nil || len(seed) == 0 {
apiutils.BadRequest(rw, r, errors.New("invalid powSolution"))