mirror of
https://github.com/seaweedfs/seaweedfs.git
synced 2024-01-19 02:48:24 +00:00
rename function
This commit is contained in:
parent
ed3b0f81c6
commit
c6a0704019
|
@ -76,7 +76,7 @@ func (s3a *S3ApiServer) exists(parentDirectoryPath string, entryName string, isD
|
|||
|
||||
}
|
||||
|
||||
func (s3a *S3ApiServer) get(parentDirectoryPath, entryName string) (entry *filer_pb.Entry, err error) {
|
||||
func (s3a *S3ApiServer) getEntry(parentDirectoryPath, entryName string) (entry *filer_pb.Entry, err error) {
|
||||
fullPath := util.NewFullPath(parentDirectoryPath, entryName)
|
||||
return filer_pb.GetEntry(s3a, fullPath)
|
||||
}
|
||||
|
|
|
@ -120,7 +120,7 @@ func (s3a *S3ApiServer) DeleteBucketHandler(w http.ResponseWriter, r *http.Reque
|
|||
|
||||
bucket, _ := getBucketAndObject(r)
|
||||
|
||||
entry, err := s3a.get(s3a.option.BucketsPath, bucket)
|
||||
entry, err := s3a.getEntry(s3a.option.BucketsPath, bucket)
|
||||
if entry == nil || err == filer_pb.ErrNotFound {
|
||||
writeErrorResponse(w, s3err.ErrNoSuchBucket, r.URL)
|
||||
return
|
||||
|
@ -164,8 +164,8 @@ func (s3a *S3ApiServer) HeadBucketHandler(w http.ResponseWriter, r *http.Request
|
|||
|
||||
bucket, _ := getBucketAndObject(r)
|
||||
|
||||
entry, err := s3a.get(s3a.option.BucketsPath, bucket)
|
||||
if entry == nil || err != nil {
|
||||
entry, err := s3a.getEntry(s3a.option.BucketsPath, bucket)
|
||||
writeErrorResponse(w, s3err.ErrNoSuchBucket, r.URL)
|
||||
return
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue