Skip to content
This repository has been archived by the owner on May 23, 2022. It is now read-only.

Commit

Permalink
better Uri
Browse files Browse the repository at this point in the history
  • Loading branch information
TBirdSoars committed Aug 19, 2021
1 parent 2c7cc5f commit eb00609
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ private static async Task Main()
{
// Get download URL
string build_Path_and_Query = buildTable.Rows[0]["build"].ToString().Replace("amp;", "");
Uri downloadURL = new Uri(baseURL + build_Path_and_Query);
Uri downloadURL = new Uri(baseURL, build_Path_and_Query);


// Get name of extract folder
Expand Down Expand Up @@ -222,7 +222,7 @@ private static async Task DownloadArchive(Uri uri, string dest)
using (Stream stream = await httpResponseMessage.Content.ReadAsStreamAsync())
{
FileInfo fileInfo = new FileInfo(dest);

using (FileStream fileStream = fileInfo.OpenWrite())
{
stream.CopyTo(fileStream);
Expand Down

0 comments on commit eb00609

Please sign in to comment.