mirror of
https://github.com/seaweedfs/seaweedfs.git
synced 2025-09-22 22:43:33 +08:00
fix has changes false if deleted result size eq zero (#4909)
* fix has changes false if deleted result size eq zero https://github.com/seaweedfs/seaweedfs/issues/4171 * fix change respos status 202 to 304 if the file has already been deleted https://github.com/seaweedfs/seaweedfs/issues/4171 * fix delete if set apply changes https://github.com/seaweedfs/seaweedfs/issues/4171 --------- Co-authored-by: Konstantin Lebedev <9497591+kmlebedev@users.noreply.github.co>
This commit is contained in:

committed by
GitHub

parent
35b5264ab7
commit
edee91ef0e
@@ -87,6 +87,11 @@ func (vs *VolumeServer) BatchDelete(ctx context.Context, req *volume_server_pb.B
|
||||
Status: http.StatusInternalServerError,
|
||||
Error: err.Error()},
|
||||
)
|
||||
} else if size == 0 {
|
||||
resp.Results = append(resp.Results, &volume_server_pb.DeleteResult{
|
||||
FileId: fid,
|
||||
Status: http.StatusNotModified},
|
||||
)
|
||||
} else {
|
||||
resp.Results = append(resp.Results, &volume_server_pb.DeleteResult{
|
||||
FileId: fid,
|
||||
|
Reference in New Issue
Block a user