diff options
Diffstat (limited to 'xmpp')
-rw-r--r-- | xmpp/component.go | 4 | ||||
-rw-r--r-- | xmpp/handlers.go | 1 |
2 files changed, 4 insertions, 1 deletions
diff --git a/xmpp/component.go b/xmpp/component.go index e484e99..d55ed6b 100644 --- a/xmpp/component.go +++ b/xmpp/component.go @@ -8,7 +8,9 @@ import ( "gosrc.io/xmpp" ) -func NewComponent(conf config.XmppConfig) *xmpp.StreamManager { +// NewComponent starts a new component and wraps it in +// a stream manager that you should start yourself +func NewComponent(conf config.XMPPConfig) *xmpp.StreamManager { options := xmpp.ComponentOptions{ Address: conf.Host + ":" + conf.Port, Domain: conf.Jid, diff --git a/xmpp/handlers.go b/xmpp/handlers.go index 38bbe7a..874af49 100644 --- a/xmpp/handlers.go +++ b/xmpp/handlers.go @@ -8,6 +8,7 @@ import ( "gosrc.io/xmpp/stanza" ) +// HandleMessage processes an incoming XMPP message func HandleMessage(s xmpp.Sender, p stanza.Packet) { msg, ok := p.(stanza.Message) if !ok { |