Skip to content

Commit

Permalink
PWX-31645 remove required path arg for fstrim (#2274)
Browse files Browse the repository at this point in the history
Signed-off-by: Chia-Chun Lin <[email protected]>
  • Loading branch information
chiachunlin authored Jul 14, 2023
1 parent 8bdb3c7 commit 8b92174
Showing 1 changed file with 0 additions and 12 deletions.
12 changes: 0 additions & 12 deletions api/server/sdk/filesystem_trim.go
Original file line number Diff line number Diff line change
Expand Up @@ -47,9 +47,6 @@ func (s *FilesystemTrimServer) Start(
if len(req.GetVolumeId()) == 0 {
return nil, status.Error(codes.InvalidArgument, "Must supply a volume id")
}
if len(req.GetMountPath()) == 0 {
return nil, status.Error(codes.InvalidArgument, "Must supply a volume mount path")
}

r, err := s.driver(ctx).FilesystemTrimStart(req)

Expand All @@ -66,12 +63,6 @@ func (s *FilesystemTrimServer) Status(
return nil, status.Error(codes.Unavailable, "Resource has not been initialized")
}
var err error
if len(req.GetVolumeId()) == 0 {
return nil, status.Error(codes.InvalidArgument, "Must supply a volume id")
}
if len(req.GetMountPath()) == 0 {
return nil, status.Error(codes.InvalidArgument, "Must supply a volume mount path")
}

r, err := s.driver(ctx).FilesystemTrimStatus(req)

Expand Down Expand Up @@ -121,9 +112,6 @@ func (s *FilesystemTrimServer) Stop(
if len(req.GetVolumeId()) == 0 {
return nil, status.Error(codes.InvalidArgument, "Must supply a volume id")
}
if len(req.GetMountPath()) == 0 {
return nil, status.Error(codes.InvalidArgument, "Must supply a volume mount path")
}

r, err := s.driver(ctx).FilesystemTrimStop(req)

Expand Down

0 comments on commit 8b92174

Please sign in to comment.