mirror of https://github.com/Xhofe/alist
fix: friendly tip for initial logging in [skip ci] (#3406)
* refactor: friendly tip for initial logging in * fix CodeFactor issue more info pls refer to: https://segmentfault.com/a/1190000043031147pull/3495/head
parent
fcaf485e0b
commit
ee77c3b113
|
@ -15,6 +15,10 @@ func GetStorageAndActualPath(rawPath string) (storage driver.Driver, actualPath
|
|||
rawPath = utils.FixAndCleanPath(rawPath)
|
||||
storage = GetBalancedStorage(rawPath)
|
||||
if storage == nil {
|
||||
if rawPath == "/" {
|
||||
err = errors.New("please add a storage first.")
|
||||
return
|
||||
}
|
||||
err = errors.Errorf("can't find storage with rawPath: %s", rawPath)
|
||||
return
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue