Fix a ingest path error

Signed-off-by: Yanqiang Miao <miao.yanqiang@zte.com.cn>
This commit is contained in:
Yanqiang Miao 2017-03-30 15:41:21 +08:00
parent 46154a6764
commit 7b188f27f4
1 changed files with 3 additions and 4 deletions

View File

@ -138,13 +138,12 @@ func (cs *Store) Walk(fn WalkFunc) error {
})
}
// Stat returns the current status of a blob by the ingest ref.
// Status returns the current status of a blob by the ingest ref.
func (s *Store) Status(ref string) (Status, error) {
dp := filepath.Join(s.ingestRoot(ref), "data")
return s.status(dp)
return s.status(s.ingestRoot(ref))
}
// stat works like stat above except uses the path to the ingest.
// status works like stat above except uses the path to the ingest.
func (s *Store) status(ingestPath string) (Status, error) {
dp := filepath.Join(ingestPath, "data")
fi, err := os.Stat(dp)