Merge pull request #87 from cooox/master

Fix MUC NoHistory invalid XML
This commit is contained in:
mattn 2017-09-11 16:18:41 +09:00 committed by GitHub
commit e015f92cdf

View File

@ -90,7 +90,8 @@ func (c *Client) JoinProtectedMUC(jid, nick string, password string, history_typ
case NoHistory: case NoHistory:
return fmt.Fprintf(c.conn, "<presence to='%s/%s'>\n" + return fmt.Fprintf(c.conn, "<presence to='%s/%s'>\n" +
"<x xmlns='%s'>\n" + "<x xmlns='%s'>\n" +
"<password>%s</password>\n"+ "<password>%s</password>" +
"</x>\n" +
"</presence>", "</presence>",
xmlEscape(jid), xmlEscape(nick), nsMUC, xmlEscape(password)) xmlEscape(jid), xmlEscape(nick), nsMUC, xmlEscape(password))
case CharHistory: case CharHistory: