From fe5050c0a5b1ef3dddde294d64ab24d8ba26e53f Mon Sep 17 00:00:00 2001 From: Kevin Liu Date: Wed, 18 Aug 2021 04:41:30 -0700 Subject: Add and use M_ROOM_IN_USE (#1972) Signed-off-by: nivekuil Co-authored-by: Neil Alexander --- clientapi/jsonerror/jsonerror.go | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'clientapi/jsonerror/jsonerror.go') diff --git a/clientapi/jsonerror/jsonerror.go b/clientapi/jsonerror/jsonerror.go index 7accde5f..caa216e6 100644 --- a/clientapi/jsonerror/jsonerror.go +++ b/clientapi/jsonerror/jsonerror.go @@ -111,6 +111,12 @@ func UserInUse(msg string) *MatrixError { return &MatrixError{"M_USER_IN_USE", msg} } +// RoomInUse is an error returned when the client tries to make a room +// that already exists +func RoomInUse(msg string) *MatrixError { + return &MatrixError{"M_ROOM_IN_USE", msg} +} + // ASExclusive is an error returned when an application service tries to // register an username that is outside of its registered namespace, or if a // user attempts to register a username or room alias within an exclusive -- cgit v1.2.3