set filer2.ErrNotFound for not found entry

This commit is contained in:
Chris Lu committed 2018-07-20 02:14:18 -07:00
1 parent dad733086a
commit 80d80daf64
5 files changed
+21 -14

No files matched your search

@@ -64,7 +64,7 @@ func (store *AbstractSqlStore) FindEntry(fullpath filer2.FullPath) (*filer2.Entr
row := store.DB.QueryRow(store.SqlFind, hashToLong(dir), name, dir)
var data []byte
if err := row.Scan(&data); err != nil {
return nil, fmt.Errorf("read entry %s: %v", fullpath, err)
return nil, filer2.ErrNotFound
}
entry := &filer2.Entry{