From: Badlop Date: Sat, 17 Dec 2016 10:45:28 +0000 (+0100) Subject: Extract correctly the text from #stanza_error (#1425) X-Git-Tag: 16.12~2 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=3811a6157330a6b82465973e622c23f2648d4fa5;p=ejabberd Extract correctly the text from #stanza_error (#1425) --- diff --git a/src/mod_muc_room.erl b/src/mod_muc_room.erl index 07689db19..a172bd38c 100644 --- a/src/mod_muc_room.erl +++ b/src/mod_muc_room.erl @@ -1264,12 +1264,7 @@ get_error_condition(undefined) -> "undefined". get_error_text(Error) -> - case fxml:get_subtag_with_xmlns(Error, <<"text">>, ?NS_STANZAS) of - #xmlel{} = Tag -> - fxml:get_tag_cdata(Tag); - false -> - <<"">> - end. + (Error#stanza_error.text)#text.data. -spec make_reason(stanza(), jid(), state(), binary()) -> binary(). make_reason(Packet, From, StateData, Reason1) ->