forked from TrueCloudLab/rclone
mega: fix error handling broken by removal of github.com/pkg/errors
There were instances of errors.Wrap being called with a nil error which the conversion didn't deal with correctly.
This commit is contained in:
parent
21ba4d9a18
commit
7366e97dfc
1 changed files with 4 additions and 1 deletions
|
@ -602,7 +602,10 @@ func (f *Fs) Mkdir(ctx context.Context, dir string) error {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
_, err = f.mkdir(ctx, rootNode, dir)
|
_, err = f.mkdir(ctx, rootNode, dir)
|
||||||
return fmt.Errorf("Mkdir failed: %w", err)
|
if err != nil {
|
||||||
|
return fmt.Errorf("Mkdir failed: %w", err)
|
||||||
|
}
|
||||||
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
// deleteNode removes a file or directory, observing useTrash
|
// deleteNode removes a file or directory, observing useTrash
|
||||||
|
|
Loading…
Reference in a new issue