Fix condition to read save data from request body
parent
977a05049e
commit
d97e07b522
|
@ -159,8 +159,8 @@ func (s *Server) ServeHTTP(w http.ResponseWriter, r *http.Request) {
|
|||
}
|
||||
|
||||
var save any
|
||||
// /savedata/delete specifies datatype, but doesn't expect data in body
|
||||
if r.URL.Path != "/savedata/delete" {
|
||||
// /savedata/get and /savedata/delete specify datatype, but don't expect data in body
|
||||
if r.URL.Path != "/savedata/get" && r.URL.Path != "/savedata/delete" {
|
||||
if datatype == 0 {
|
||||
var system defs.SystemSaveData
|
||||
err = json.NewDecoder(r.Body).Decode(&system)
|
||||
|
|
Loading…
Reference in New Issue