mirror of
https://github.com/navidrome/navidrome.git
synced 2025-04-05 05:27:37 +03:00
Fix DB migration. Fix #2168
This commit is contained in:
parent
3cd934abd7
commit
2400e4f60d
1 changed files with 4 additions and 3 deletions
|
@ -27,15 +27,16 @@ func upChangeImageFilesListSeparator(tx *sql.Tx) error {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
|
||||||
var id, imageFiles string
|
var id string
|
||||||
|
var imageFiles sql.NullString
|
||||||
for rows.Next() {
|
for rows.Next() {
|
||||||
err = rows.Scan(&id, &imageFiles)
|
err = rows.Scan(&id, &imageFiles)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
|
||||||
files := upChangeImageFilesListSeparatorDirs(imageFiles)
|
files := upChangeImageFilesListSeparatorDirs(imageFiles.String)
|
||||||
if files == imageFiles {
|
if files == imageFiles.String {
|
||||||
continue
|
continue
|
||||||
}
|
}
|
||||||
_, err = stmt.Exec(files, id)
|
_, err = stmt.Exec(files, id)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue