fix nil problem

This commit is contained in:
Chris Lu
2019-12-10 23:13:14 -08:00
parent 356bd1b629
commit 40ff4eea14
2 changed files with 6 additions and 2 deletions

View File

@@ -112,11 +112,12 @@ func GetEntry(ctx context.Context, filerClient FilerClient, fullFilePath string)
return err
}
if resp.Entry != nil {
entry = resp.Entry
if resp.Entry == nil {
glog.V(3).Infof("read %s entry: %v", fullFilePath, entry)
return nil
}
entry = resp.Entry
return nil
})