summaryrefslogtreecommitdiffstats
path: root/bridge/config/config.go
diff options
context:
space:
mode:
authorWim <wim@42.be>2017-12-19 23:15:03 +0100
committerWim <wim@42.be>2017-12-19 23:15:03 +0100
commit265457b45171dcae96a1aac9454e3bda2cd0557a (patch)
tree35342a6b83e01b708b20442378799c7692fdf519 /bridge/config/config.go
parent4a4a29c9f6fe202cf4379c0df2ba313848bb8d11 (diff)
downloadmatterbridge-msglm-265457b45171dcae96a1aac9454e3bda2cd0557a.tar.gz
matterbridge-msglm-265457b45171dcae96a1aac9454e3bda2cd0557a.tar.bz2
matterbridge-msglm-265457b45171dcae96a1aac9454e3bda2cd0557a.zip
Refactor and add MediaDownloadSize to General
Diffstat (limited to 'bridge/config/config.go')
-rw-r--r--bridge/config/config.go8
1 files changed, 8 insertions, 0 deletions
diff --git a/bridge/config/config.go b/bridge/config/config.go
index 6344fa59..10f1d5f0 100644
--- a/bridge/config/config.go
+++ b/bridge/config/config.go
@@ -60,6 +60,7 @@ type Protocol struct {
IgnoreMessages string // all protocols
Jid string // xmpp
Login string // mattermost, matrix
+ MediaDownloadSize int // all protocols
MediaServerDownload string
MediaServerUpload string
MessageDelay int // IRC, time in millisecond to wait between messages
@@ -147,6 +148,13 @@ type Config struct {
SameChannelGateway []SameChannelGateway
}
+type BridgeConfig struct {
+ Config Protocol
+ General *Protocol
+ Account string
+ Remote chan Message
+}
+
func NewConfig(cfgfile string) *Config {
var cfg Config
if _, err := toml.DecodeFile(cfgfile, &cfg); err != nil {