mirror of
https://github.com/hoernschen/dendrite.git
synced 2025-08-02 22:22:46 +00:00
Merge branch 'master' into neilalexander/sqlite-roomserver
This commit is contained in:
commit
7a71a59dc7
8 changed files with 26 additions and 8 deletions
|
@ -62,7 +62,9 @@ type Database interface {
|
|||
func Open(dataSourceName string) (Database, error) {
|
||||
uri, err := url.Parse(dataSourceName)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
// if the scheme doesn't match, fall back to postgres in case the config has
|
||||
// postgres key=value connection strings
|
||||
return postgres.Open(dataSourceName)
|
||||
}
|
||||
switch uri.Scheme {
|
||||
case "postgres":
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue