mirror of
https://github.com/davidallendj/magellan.git
synced 2025-12-20 03:27:03 -07:00
cache: refactor after updating util
This commit is contained in:
parent
036a5d3ab7
commit
e87b2184a2
1 changed files with 1 additions and 3 deletions
4
internal/cache/sqlite/sqlite.go
vendored
4
internal/cache/sqlite/sqlite.go
vendored
|
|
@ -85,11 +85,9 @@ func DeleteScannedAssets(path string, results ...magellan.RemoteAsset) error {
|
|||
|
||||
func GetScannedAssets(path string) ([]magellan.RemoteAsset, error) {
|
||||
// check if path exists first to prevent creating the database
|
||||
exists, err := util.PathExists(path)
|
||||
_, exists := util.PathExists(path)
|
||||
if !exists {
|
||||
return nil, fmt.Errorf("no file found")
|
||||
} else if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
// now check if the file is the SQLite database
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue