/me endpoint and slightly refactored auth

This commit is contained in:
2026-03-20 09:26:40 +05:00
parent 34363ce649
commit f7b205bbf6
2 changed files with 34 additions and 4 deletions

View File

@@ -158,7 +158,7 @@ func (s *Server) JSON(w http.ResponseWriter, r *http.Request, status int, payloa
Success: &success,
Data: &map[string]interface{}{respType: payload},
}
w.Header().Set("Content-Type", "applicaton/json; charset=utf-8")
w.Header().Set("Content-Type", "application/json; charset=utf-8")
w.WriteHeader(status)
if err := json.NewEncoder(w).Encode(resp); err != nil {