1
0
mirror of https://github.com/thebaer/cdr.git synced 2024-11-15 01:31:01 +00:00

Fix file scanning error condition

This commit is contained in:
Matt Baer 2020-02-26 00:16:09 -05:00
parent f0aa182c03
commit 79db8a0cd1

View File

@ -25,7 +25,7 @@ func newMixtape(wd string) (*cdr.Mixtape, error) {
filepath.Walk(wd, func(path string, i os.FileInfo, err error) error {
if !i.IsDir() && !strings.HasPrefix(i.Name(), ".") && i.Name() != "index.html" {
t, err := cdr.NewTrack(i.Name())
if err == nil {
if err != nil {
log.Printf("Skipping track %s: %v", i.Name(), err)
return nil
}