PutUnchecked uploads the object This will create a duplicate if we upload a new file without checking to see if there is one already - use Put() for that.
(ctx context.Context, in io.Reader, src fs.ObjectInfo, options ...fs.OpenOption)
| 716 | // This will create a duplicate if we upload a new file without |
| 717 | // checking to see if there is one already - use Put() for that. |
| 718 | func (f *Fs) PutUnchecked(ctx context.Context, in io.Reader, src fs.ObjectInfo, options ...fs.OpenOption) (fs.Object, error) { |
| 719 | do := f.Fs.Features().PutUnchecked |
| 720 | if do == nil { |
| 721 | return nil, errors.New("can't PutUnchecked") |
| 722 | } |
| 723 | wrappedIn, encrypter, err := f.cipher.encryptData(in) |
| 724 | if err != nil { |
| 725 | return nil, err |
| 726 | } |
| 727 | o, err := do(ctx, wrappedIn, f.newObjectInfo(src, encrypter.nonce)) |
| 728 | if err != nil { |
| 729 | return nil, err |
| 730 | } |
| 731 | return f.newObject(o), nil |
| 732 | } |
| 733 | |
| 734 | // CleanUp the trash in the Fs |
| 735 | // |
nothing calls this directly
no test coverage detected