Fix: user storage might be returned twice when OneDrive uploading canceled in WebDAV requests

This commit is contained in:
HFO4
2020-12-01 19:22:52 +08:00
parent 33f8419999
commit 7279be2924
6 changed files with 88 additions and 6 deletions

View File

@@ -193,7 +193,7 @@ func TestDriver_Source(t *testing.T) {
{
handler.Policy.BaseURL = ""
handler.Policy.OptionsSerialized.ServerSideEndpoint = "endpoint.com"
res, err := handler.Source(context.WithValue(context.Background(), fsctx.ForceUsePublicEndpoint, false), "/123", url.URL{}, 10, false, 0)
res, err := handler.Source(context.WithValue(context.Background(), fsctx.ForceUsePublicEndpointCtx, false), "/123", url.URL{}, 10, false, 0)
asserts.NoError(err)
resURL, err := url.Parse(res)
asserts.NoError(err)