Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: add required extract parameter to file upload #311

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -98,15 +98,19 @@ public async Task<Stream> GetFileAsync(
/// <param name="filepath">The path to the file we are uploading.</param>
/// <param name="subPath">An optional subpath to the folder.</param>
/// <param name="packageFullName">The package full name if using LocalAppData.</param>
/// <param name="shouldExtract">The indication if the file should be extracted after upload.</param>
/// <returns>Task tracking completion of the upload request.</returns>
public async Task UploadFileAsync(
string knownFolderId,
string filepath,
string subPath = null,
string packageFullName = null)
string packageFullName = null,
bool shouldExtract = false)
{
Dictionary<string, string> payload = this.BuildCommonFilePayload(knownFolderId, subPath, packageFullName);

payload.Add("extract", shouldExtract.ToString());

List<string> files = new List<string>();
files.Add(filepath);

Expand Down