mirror of
https://forge.fsky.io/lda/Parsee.git
synced 2026-03-13 17:05:11 +00:00
[FIX] Saner way to filter stanzas
This commit is contained in:
parent
729d107400
commit
f743a33643
1 changed files with 2 additions and 2 deletions
|
|
@ -24,6 +24,7 @@ MessageStanza(ParseeData *args, XMLElement *stanza, XMPPThread *thr)
|
|||
char *retracted = XMPPGetRetractedID(stanza);
|
||||
char *reply_to = XMPPGetReply(stanza);
|
||||
char *moderated = XMPPGetModeration(stanza);
|
||||
bool chat = StrEquals(HashMapGet(stanza->attrs, "type"), "chat");
|
||||
size_t i;
|
||||
|
||||
to = NULL;
|
||||
|
|
@ -182,7 +183,7 @@ MessageStanza(ParseeData *args, XMLElement *stanza, XMPPThread *thr)
|
|||
* ISSUE.
|
||||
*
|
||||
* I HATE THIS. I NEED TO FIND A BETTER WAY. */
|
||||
if (mroom_id)
|
||||
if (!chat)
|
||||
{
|
||||
if (strncmp(HashMapGet(stanza->attrs, "to"), "parsee@", 7))
|
||||
{
|
||||
|
|
@ -195,7 +196,6 @@ MessageStanza(ParseeData *args, XMLElement *stanza, XMPPThread *thr)
|
|||
char *res = ParseeGetResource(from);
|
||||
char *encoded = ParseeGetBridgedUser(args, stanza);
|
||||
char *event_id = NULL;
|
||||
bool chat = StrEquals(HashMapGet(stanza->attrs, "type"), "chat");
|
||||
|
||||
{
|
||||
char *parsee = ParseeJID(args);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue