mirror of
https://github.com/mattermost/mattermost.git
synced 2026-05-28 04:35:04 -04:00
MM-55450: Handle error in db migrate phase (#25430)
We were not handling the error from initConnection. https://mattermost.atlassian.net/browse/MM-55450 ```release-note NONE ```
This commit is contained in:
parent
fee6606606
commit
864046f782
1 changed files with 4 additions and 1 deletions
|
|
@ -37,7 +37,10 @@ func NewMigrator(settings model.SqlSettings, dryRun bool) (*Migrator, error) {
|
|||
wgMonitor: &sync.WaitGroup{},
|
||||
}
|
||||
|
||||
ss.initConnection()
|
||||
err := ss.initConnection()
|
||||
if err != nil {
|
||||
return nil, fmt.Errorf("error in initializing connection: %w", err)
|
||||
}
|
||||
|
||||
ver, err := ss.GetDbVersion(true)
|
||||
if err != nil {
|
||||
|
|
|
|||
Loading…
Reference in a new issue