summaryrefslogtreecommitdiffstats
path: root/matterclient
diff options
context:
space:
mode:
authorWim <wim@42.be>2017-07-22 18:13:13 +0200
committerWim <wim@42.be>2017-07-22 18:13:13 +0200
commit10dab1366e023ba5327ffd8d262a1ff8121764a2 (patch)
tree185590647b502fffa41e6f4d712ae52e6fecc58e /matterclient
parent52fc94c1fe4f4615d776ce0c2a7e87c774e3cd53 (diff)
downloadmatterbridge-msglm-10dab1366e023ba5327ffd8d262a1ff8121764a2.tar.gz
matterbridge-msglm-10dab1366e023ba5327ffd8d262a1ff8121764a2.tar.bz2
matterbridge-msglm-10dab1366e023ba5327ffd8d262a1ff8121764a2.zip
Return better error messages on mattermost connect
Diffstat (limited to 'matterclient')
-rw-r--r--matterclient/matterclient.go5
1 files changed, 4 insertions, 1 deletions
diff --git a/matterclient/matterclient.go b/matterclient/matterclient.go
index 75d883f3..7ca7a0b1 100644
--- a/matterclient/matterclient.go
+++ b/matterclient/matterclient.go
@@ -112,7 +112,10 @@ func (m *MMClient) Login() error {
for {
d := b.Duration()
// bogus call to get the serverversion
- m.Client.GetClientProperties()
+ _, err := m.Client.GetClientProperties()
+ if err != nil {
+ return fmt.Errorf("%#v", err.Error())
+ }
if firstConnection && !supportedVersion(m.Client.ServerVersion) {
return fmt.Errorf("unsupported mattermost version: %s", m.Client.ServerVersion)
}