reload user after resetting mecount
Ted Unangst tedu@tedunangst.com
Mon, 05 Feb 2024 22:58:06 -0500
1 files changed,
2 insertions(+),
1 deletions(-)
jump to
M
web.go
→
web.go
@@ -2550,7 +2550,6 @@ userid := u.UserID
action := r.FormValue("action") wait, _ := strconv.ParseInt(r.FormValue("wait"), 10, 0) dlog.Printf("api request '%s' on behalf of %s", action, u.Username) - user, _ := butwhatabout(u.Username) switch action { case "honk": h := submithonk(w, r)@@ -2626,6 +2625,7 @@ case <-waitchan:
} } reverbolate(userid, honks) + user, _ := butwhatabout(u.Username) j := junk.New() j["honks"] = honks j["mecount"] = user.Options.MeCount@@ -2633,6 +2633,7 @@ j["chatcount"] = user.Options.ChatCount
j.Write(w) case "sendactivity": public := r.FormValue("public") == "1" + user, _ := butwhatabout(u.Username) rcpts := boxuprcpts(user, r.Form["rcpt"], public) msg := []byte(r.FormValue("msg")) for rcpt := range rcpts {