Do not attach Genres to the "Various Artists" artist
This commit is contained in:
@@ -11,6 +11,7 @@ import (
|
|||||||
"github.com/astaxie/beego/orm"
|
"github.com/astaxie/beego/orm"
|
||||||
"github.com/deluan/rest"
|
"github.com/deluan/rest"
|
||||||
"github.com/navidrome/navidrome/conf"
|
"github.com/navidrome/navidrome/conf"
|
||||||
|
"github.com/navidrome/navidrome/consts"
|
||||||
"github.com/navidrome/navidrome/log"
|
"github.com/navidrome/navidrome/log"
|
||||||
"github.com/navidrome/navidrome/model"
|
"github.com/navidrome/navidrome/model"
|
||||||
"github.com/navidrome/navidrome/utils"
|
"github.com/navidrome/navidrome/utils"
|
||||||
@@ -66,6 +67,9 @@ func (r *artistRepository) Put(a *model.Artist) error {
|
|||||||
if err != nil {
|
if err != nil {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
if a.ID == consts.VariousArtistsID {
|
||||||
|
return r.updateGenres(a.ID, r.tableName, nil)
|
||||||
|
}
|
||||||
return r.updateGenres(a.ID, r.tableName, a.Genres)
|
return r.updateGenres(a.ID, r.tableName, a.Genres)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user