diff --git a/drivers/native/driver.go b/drivers/native/driver.go index 601e30f9..ecb4ec7e 100644 --- a/drivers/native/driver.go +++ b/drivers/native/driver.go @@ -118,6 +118,10 @@ func (driver Native) Files(path string, account *model.Account) ([]model.File, e } func (driver Native) Link(args base.Args, account *model.Account) (*base.Link, error) { + _, err := driver.File(args.Path, account) + if err != nil { + return nil, err + } fullPath := filepath.Join(account.RootFolder, args.Path) s, err := os.Stat(fullPath) if err != nil {