0
0
Fork 0
mirror of https://github.com/matrix-org/dendrite synced 2024-12-14 20:03:52 +01:00

Decode uri values correctly

This commit is contained in:
Kegan Dougal 2021-01-13 22:27:04 +00:00
parent 3183f75aed
commit 19392c8c6b

View file

@ -97,7 +97,10 @@ func spacesHandler(db Database, rsAPI roomserver.RoomserverInternalAPI) func(*ht
inMemoryBatchCache := make(map[string]set)
return func(req *http.Request, device *userapi.Device) util.JSONResponse {
// Extract the room ID from the request. Sanity check request data.
params := mux.Vars(req)
params, err := httputil.URLDecodeMapValues(mux.Vars(req))
if err != nil {
return util.ErrorResponse(err)
}
roomID := params["roomID"]
var r SpacesRequest
r.Defaults()