vfs: add context parameter to New() for config propagation
Add a ctx parameter to vfs.New() so callers can pass in context carrying ConfigInfo and FilterInfo. The context is stripped of cancellation but config and filter values are preserved into a fresh background context.
This commit is contained in:
@@ -263,7 +263,7 @@ func newWebDAV(ctx context.Context, f fs.Fs, opt *Options, vfsOpt *vfscommon.Opt
|
||||
// override auth
|
||||
w.opt.Auth.CustomAuthFn = w.auth
|
||||
} else {
|
||||
w._vfs = vfs.New(f, vfsOpt)
|
||||
w._vfs = vfs.New(ctx, f, vfsOpt)
|
||||
}
|
||||
|
||||
w.server, err = libhttp.NewServer(ctx,
|
||||
|
||||
Reference in New Issue
Block a user