Skip to content

Commit

Permalink
Return FSM state from function
Browse files Browse the repository at this point in the history
Without this change, the FSM would crash.
  • Loading branch information
gustawlippa committed Oct 29, 2024
1 parent d5584c9 commit c4f2826
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/muc/mod_muc_room.erl
Original file line number Diff line number Diff line change
Expand Up @@ -1183,7 +1183,8 @@ handle_new_user(From, Nick, Packet, StateData, Attrs) ->
case exml_query:path(Packet, [{element, <<"x">>}]) of
undefined ->
Response = kick_stanza_for_old_protocol(Attrs),
ejabberd_router:route(jid:replace_resource(StateData#state.jid, Nick), From, Response);
ejabberd_router:route(jid:replace_resource(StateData#state.jid, Nick), From, Response),
StateData;

Check warning on line 1187 in src/muc/mod_muc_room.erl

View check run for this annotation

Codecov / codecov/patch

src/muc/mod_muc_room.erl#L1186-L1187

Added lines #L1186 - L1187 were not covered by tests
_ ->
add_new_user(From, Nick, Packet, StateData)
end.
Expand Down

0 comments on commit c4f2826

Please sign in to comment.