mirror of
https://github.com/navidrome/navidrome.git
synced 2025-04-03 20:47:35 +03:00
Remove non-album artist_ids from the DB
This commit is contained in:
parent
0d9dcebf32
commit
1c82bf5179
5 changed files with 53 additions and 1 deletions
|
@ -135,6 +135,11 @@ func (s *SQLStore) GC(ctx context.Context, rootFolder string) error {
|
|||
log.Error(ctx, "Error removing dangling tracks", err)
|
||||
return err
|
||||
}
|
||||
err = s.MediaFile(ctx).(*mediaFileRepository).removeNonAlbumArtistIds()
|
||||
if err != nil {
|
||||
log.Error(ctx, "Error removing non-album artist_ids", err)
|
||||
return err
|
||||
}
|
||||
err = s.Album(ctx).(*albumRepository).purgeEmpty()
|
||||
if err != nil {
|
||||
log.Error(ctx, "Error removing empty albums", err)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue