mirror of
https://github.com/navidrome/navidrome.git
synced 2025-07-27 05:38:22 +03:00
Silly bug... Where are the tests?!?
This commit is contained in:
parent
0e492a053c
commit
56e9ad3def
@ -43,8 +43,6 @@ func (s *ItunesScanner) ScanLibrary(lastModifiedSince time.Time, path string) (i
|
|||||||
ar := s.collectArtists(&t)
|
ar := s.collectArtists(&t)
|
||||||
mf := s.collectMediaFiles(&t)
|
mf := s.collectMediaFiles(&t)
|
||||||
s.collectAlbums(&t, mf, ar)
|
s.collectAlbums(&t, mf, ar)
|
||||||
} else {
|
|
||||||
beego.Trace("Skipped", t.Location, " - kind:", t.Kind)
|
|
||||||
}
|
}
|
||||||
i++
|
i++
|
||||||
if i%1000 == 0 {
|
if i%1000 == 0 {
|
||||||
@ -94,13 +92,13 @@ func (s *ItunesScanner) collectMediaFiles(t *itl.Track) *domain.MediaFile {
|
|||||||
mf.Path = path
|
mf.Path = path
|
||||||
mf.Suffix = strings.TrimPrefix(filepath.Ext(path), ".")
|
mf.Suffix = strings.TrimPrefix(filepath.Ext(path), ".")
|
||||||
|
|
||||||
|
mf.CreatedAt = t.DateAdded
|
||||||
|
mf.UpdatedAt = t.DateModified
|
||||||
|
|
||||||
if mf.UpdatedAt.After(s.lastModifiedSince) {
|
if mf.UpdatedAt.After(s.lastModifiedSince) {
|
||||||
mf.HasCoverArt = hasCoverArt(path)
|
mf.HasCoverArt = hasCoverArt(path)
|
||||||
}
|
}
|
||||||
|
|
||||||
mf.CreatedAt = t.DateAdded
|
|
||||||
mf.UpdatedAt = t.DateModified
|
|
||||||
|
|
||||||
s.mediaFiles[mf.Id] = mf
|
s.mediaFiles[mf.Id] = mf
|
||||||
|
|
||||||
return mf
|
return mf
|
||||||
|
Loading…
x
Reference in New Issue
Block a user