Refactored logic from getMusicDirectory.view to the new engine layer.
This reveled a nasty bug in the DI code. Tests are broken
This commit is contained in:
@@ -4,6 +4,7 @@ import (
|
||||
"encoding/json"
|
||||
"errors"
|
||||
"fmt"
|
||||
|
||||
"github.com/deluan/gosonic/domain"
|
||||
)
|
||||
|
||||
@@ -34,9 +35,6 @@ func (m *MockArtist) SetData(j string, size int) {
|
||||
}
|
||||
|
||||
func (m *MockArtist) Exists(id string) (bool, error) {
|
||||
if m.err {
|
||||
return false, errors.New("Error!")
|
||||
}
|
||||
_, found := m.data[id]
|
||||
return found, nil
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user