archive,cmd,fs: return err directly
Signed-off-by: Cristian Staretu <cristian.staretu@gmail.com>
This commit is contained in:
parent
d43628c930
commit
e91d6805af
4 changed files with 16 additions and 38 deletions
|
@ -57,10 +57,7 @@ func RemoveAll(name string) Applier {
|
|||
func CreateDir(name string, perm os.FileMode) Applier {
|
||||
return applyFn(func(root string) error {
|
||||
fullPath := filepath.Join(root, name)
|
||||
if err := os.MkdirAll(fullPath, perm); err != nil {
|
||||
return err
|
||||
}
|
||||
return nil
|
||||
return os.MkdirAll(fullPath, perm)
|
||||
})
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue