Remove deletes an element
(ctx context.Context, req *fuse.RemoveRequest)
| 340 | |
| 341 | // Remove deletes an element |
| 342 | func (o Object) Remove(ctx context.Context, req *fuse.RemoveRequest) error { |
| 343 | object, err := o.fs.client.GetObjectByParentAndName(o.objectID, req.Name) |
| 344 | if nil != err { |
| 345 | Log.Warningf("%v", err) |
| 346 | return fuse.EIO |
| 347 | } |
| 348 | |
| 349 | err = o.fs.client.Remove(object, o.objectID) |
| 350 | if nil != err { |
| 351 | Log.Warningf("%v", err) |
| 352 | return fuse.EIO |
| 353 | } |
| 354 | |
| 355 | return nil |
| 356 | } |
| 357 | |
| 358 | // Mkdir creates a new directory |
| 359 | func (o Object) Mkdir(ctx context.Context, req *fuse.MkdirRequest) (fs.Node, error) { |
no test coverage detected