mirror of
https://github.com/pgsty/minio.git
synced 2026-07-19 20:20:25 +03:00
minor cleanup
- Reused contains() from utils.go at a couple of places - Cleanup in return statements and boolean checks
This commit is contained in:
committed by
Harshavardhana
parent
ec4260d260
commit
418921de89
+2
-10
@@ -16,11 +16,7 @@ type storageServer struct {
|
||||
|
||||
// MakeVolHandler - make vol handler is rpc wrapper for MakeVol operation.
|
||||
func (s *storageServer) MakeVolHandler(arg *string, reply *GenericReply) error {
|
||||
err := s.storage.MakeVol(*arg)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
return nil
|
||||
return s.storage.MakeVol(*arg)
|
||||
}
|
||||
|
||||
// ListVolsHandler - list vols handler is rpc wrapper for ListVols operation.
|
||||
@@ -46,11 +42,7 @@ func (s *storageServer) StatVolHandler(arg *string, reply *VolInfo) error {
|
||||
// DeleteVolHandler - delete vol handler is a rpc wrapper for
|
||||
// DeleteVol operation.
|
||||
func (s *storageServer) DeleteVolHandler(arg *string, reply *GenericReply) error {
|
||||
err := s.storage.DeleteVol(*arg)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
return nil
|
||||
return s.storage.DeleteVol(*arg)
|
||||
}
|
||||
|
||||
/// File operations
|
||||
|
||||
Reference in New Issue
Block a user