mirror of
https://github.com/matrix-org/dendrite.git
synced 2025-12-29 01:33:10 -06:00
Don't return error if the state event fails
This commit is contained in:
parent
aeecedefe7
commit
4105afd4dd
|
|
@ -77,7 +77,15 @@ func (r *RoomserverInternalAPI) SetRoomAlias(
|
||||||
// At this point we've already committed the alias to the database so we
|
// At this point we've already committed the alias to the database so we
|
||||||
// shouldn't cancel this request.
|
// shouldn't cancel this request.
|
||||||
// TODO: Ensure that we send unsent events when if server restarts.
|
// TODO: Ensure that we send unsent events when if server restarts.
|
||||||
return r.sendUpdatedAliasesEvent(context.TODO(), request.UserID, request.RoomID)
|
//
|
||||||
|
// From: https://spec.matrix.org/unstable/client-server-api/#delete_matrixclientr0directoryroomroomalias
|
||||||
|
// Note: Servers may choose to update the alt_aliases for the m.room.canonical_alias
|
||||||
|
// state event in the room when an alias is removed. Servers which choose to update
|
||||||
|
// the canonical alias event are recommended to, in addition to their other relevant
|
||||||
|
// permission checks, delete the alias and return a successful response even if the
|
||||||
|
// user does not have permission to update the m.room.canonical_alias event.
|
||||||
|
_ = r.sendUpdatedAliasesEvent(context.TODO(), request.UserID, roomID)
|
||||||
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
// GetRoomIDForAlias implements alias.RoomserverInternalAPI
|
// GetRoomIDForAlias implements alias.RoomserverInternalAPI
|
||||||
|
|
@ -172,7 +180,15 @@ func (r *RoomserverInternalAPI) RemoveRoomAlias(
|
||||||
// At this point we've already committed the alias to the database so we
|
// At this point we've already committed the alias to the database so we
|
||||||
// shouldn't cancel this request.
|
// shouldn't cancel this request.
|
||||||
// TODO: Ensure that we send unsent events when if server restarts.
|
// TODO: Ensure that we send unsent events when if server restarts.
|
||||||
return r.sendUpdatedAliasesEvent(context.TODO(), request.UserID, roomID)
|
//
|
||||||
|
// From: https://spec.matrix.org/unstable/client-server-api/#delete_matrixclientr0directoryroomroomalias
|
||||||
|
// Note: Servers may choose to update the alt_aliases for the m.room.canonical_alias
|
||||||
|
// state event in the room when an alias is removed. Servers which choose to update
|
||||||
|
// the canonical alias event are recommended to, in addition to their other relevant
|
||||||
|
// permission checks, delete the alias and return a successful response even if the
|
||||||
|
// user does not have permission to update the m.room.canonical_alias event.
|
||||||
|
_ = r.sendUpdatedAliasesEvent(context.TODO(), request.UserID, roomID)
|
||||||
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
type roomAliasesContent struct {
|
type roomAliasesContent struct {
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue