mirror of
https://mau.dev/mautrix/go.git
synced 2026-03-14 14:25:53 +01:00
Cache versions response in bridges
This commit is contained in:
parent
490422c20b
commit
befc58101a
1 changed files with 3 additions and 1 deletions
|
|
@ -165,7 +165,8 @@ type Bridge struct {
|
|||
Crypto Crypto
|
||||
CryptoPickleKey string
|
||||
|
||||
MediaConfig mautrix.RespMediaConfig
|
||||
MediaConfig mautrix.RespMediaConfig
|
||||
SpecVersions mautrix.RespVersions
|
||||
|
||||
Child ChildOverride
|
||||
|
||||
|
|
@ -252,6 +253,7 @@ func (br *Bridge) ensureConnection() {
|
|||
time.Sleep(10 * time.Second)
|
||||
continue
|
||||
}
|
||||
br.SpecVersions = *versions
|
||||
if br.Config.Homeserver.Software == bridgeconfig.SoftwareHungry && !versions.UnstableFeatures["com.beeper.hungry"] {
|
||||
br.Log.Fatalln("The config claims the homeserver is hungryserv, but the /versions response didn't confirm it")
|
||||
os.Exit(18)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue