diff options
author | Wim <wim@42.be> | 2017-12-19 23:15:03 +0100 |
---|---|---|
committer | Wim <wim@42.be> | 2017-12-19 23:15:03 +0100 |
commit | 265457b45171dcae96a1aac9454e3bda2cd0557a (patch) | |
tree | 35342a6b83e01b708b20442378799c7692fdf519 /bridge/gitter | |
parent | 4a4a29c9f6fe202cf4379c0df2ba313848bb8d11 (diff) | |
download | matterbridge-msglm-265457b45171dcae96a1aac9454e3bda2cd0557a.tar.gz matterbridge-msglm-265457b45171dcae96a1aac9454e3bda2cd0557a.tar.bz2 matterbridge-msglm-265457b45171dcae96a1aac9454e3bda2cd0557a.zip |
Refactor and add MediaDownloadSize to General
Diffstat (limited to 'bridge/gitter')
-rw-r--r-- | bridge/gitter/gitter.go | 20 |
1 files changed, 7 insertions, 13 deletions
diff --git a/bridge/gitter/gitter.go b/bridge/gitter/gitter.go index 64b6344f..fce58c1f 100644 --- a/bridge/gitter/gitter.go +++ b/bridge/gitter/gitter.go @@ -9,13 +9,11 @@ import ( ) type Bgitter struct { - c *gitter.Gitter - Config *config.Protocol - Remote chan config.Message - Account string - User *gitter.User - Users []gitter.User - Rooms []gitter.Room + c *gitter.Gitter + User *gitter.User + Users []gitter.User + Rooms []gitter.Room + *config.BridgeConfig } var flog *log.Entry @@ -25,12 +23,8 @@ func init() { flog = log.WithFields(log.Fields{"module": protocol}) } -func New(cfg config.Protocol, account string, c chan config.Message) *Bgitter { - b := &Bgitter{} - b.Config = &cfg - b.Remote = c - b.Account = account - return b +func New(cfg *config.BridgeConfig) *Bgitter { + return &Bgitter{BridgeConfig: cfg} } func (b *Bgitter) Connect() error { |