mirror of
https://github.com/hoernschen/dendrite.git
synced 2025-07-29 12:42:46 +00:00
Return M_NOT_FOUND for rejected events (#2371)
* Return M_NOT_FOUND for rejected events * Add passing tests
This commit is contained in:
parent
e95fc5c5e3
commit
e8ab2154aa
4 changed files with 31 additions and 8 deletions
|
@ -129,6 +129,13 @@ func getState(
|
|||
return nil, nil, &resErr
|
||||
}
|
||||
|
||||
if response.IsRejected {
|
||||
return nil, nil, &util.JSONResponse{
|
||||
Code: http.StatusNotFound,
|
||||
JSON: jsonerror.NotFound("Event not found"),
|
||||
}
|
||||
}
|
||||
|
||||
if !response.RoomExists {
|
||||
return nil, nil, &util.JSONResponse{Code: http.StatusNotFound, JSON: nil}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue