X-Git-Url: https://git.realraum.at/?p=svn42.git;a=blobdiff_plain;f=go%2Fr3-netstatus%2Fr3xmppbot%2Fr3xmppbot.go;h=3e6f210257ab7d1b89e7d3e2d56f4246539a9927;hp=8ee0775b18db60030d83f04ffdae57d43a3ff0dc;hb=2416b163f05370fcffb2f62bea000265d10aac42;hpb=db6096af35c81fac74bacda38c734a76b7bdf9c1 diff --git a/go/r3-netstatus/r3xmppbot/r3xmppbot.go b/go/r3-netstatus/r3xmppbot/r3xmppbot.go index 8ee0775..3e6f210 100644 --- a/go/r3-netstatus/r3xmppbot/r3xmppbot.go +++ b/go/r3-netstatus/r3xmppbot/r3xmppbot.go @@ -77,7 +77,7 @@ func (botdata *XmppBot) makeXMPPPresence(to, ptype, show, status string) *xmpp.P gen_status = nil } else { gen_status = &xmpp.Generic{Chardata: status} - } + } return &xmpp.Presence{Header: xmppmsgheader, Show: gen_show, Status: gen_status} } @@ -202,10 +202,10 @@ func (botdata *XmppBot) handleEventsforXMPP(xmppout chan <- xmpp.Stanza, presenc xmppout <- botdata.makeXMPPMessage(to, pec, nil) } } - + case XMPPStatusEvent: xmppout <- botdata.makeXMPPPresence("", "", pec.Show, pec.Status) - + case XMPPMsgEvent: if pec.RememberAsStatus { last_status_msg = &pec.Msg @@ -333,7 +333,7 @@ func (botdata *XmppBot) handleIncomingXMPPStanzas(xmppin <- chan xmpp.Stanza, xm switch stanza.GetHeader().Type { case "subscribe": xmppout <- botdata.makeXMPPPresence(stanza.GetHeader().From, "subscribed", "", "") - jabber_events <- JabberEvent{stanza.GetHeader().From, true, R3NoChange, false} + jabber_events <- JabberEvent{stanza.GetHeader().From, true, R3NoChange, false} xmppout <- botdata.makeXMPPPresence(stanza.GetHeader().From, "subscribe", "", "") case "unsubscribe", "unsubscribed": jabber_events <- JabberEvent{stanza.GetHeader().From, false, R3NeverInfo, false}