File tree Expand file tree Collapse file tree 2 files changed +6
-4
lines changed Expand file tree Collapse file tree 2 files changed +6
-4
lines changed Original file line number Diff line number Diff line change @@ -141,8 +141,10 @@ class Codes(str, Enum):
141141 INVITE_BLOCKED = "ORG.MATRIX.MSC4155.M_INVITE_BLOCKED"
142142
143143 # Part of MSC4306: Thread Subscriptions
144- SKIPPED = "M_SKIPPED"
145- NOT_IN_THREAD = "M_NOT_IN_THREAD"
144+ MSC4306_CONFLICTING_UNSUBSCRIPTION = (
145+ "IO.ELEMENT.MSC4306.M_CONFLICTING_UNSUBSCRIPTION"
146+ )
147+ MSC4306_NOT_IN_THREAD = "IO.ELEMENT.MSC4306.M_NOT_IN_THREAD"
146148
147149
148150class CodeMessageException (RuntimeError ):
Original file line number Diff line number Diff line change @@ -111,7 +111,7 @@ async def subscribe_user_to_thread(
111111 raise SynapseError (
112112 HTTPStatus .BAD_REQUEST ,
113113 "Automatic subscription must be caused by an event in the thread" ,
114- errcode = Codes .NOT_IN_THREAD ,
114+ errcode = Codes .MSC4306_NOT_IN_THREAD ,
115115 )
116116
117117 stream_ordering = event .internal_metadata .stream_ordering
@@ -135,7 +135,7 @@ async def subscribe_user_to_thread(
135135 raise SynapseError (
136136 HTTPStatus .CONFLICT ,
137137 "Automatic subscription obsoleted by an unsubscription request." ,
138- errcode = Codes .SKIPPED ,
138+ errcode = Codes .MSC4306_CONFLICTING_UNSUBSCRIPTION ,
139139 )
140140
141141 return outcome
You can’t perform that action at this time.
0 commit comments