From 9d4d09810a48815ec821b23f4c0b8b1807c831b3 Mon Sep 17 00:00:00 2001 From: Matt Portune <59324545+mportune-bw@users.noreply.github.com> Date: Mon, 25 Jan 2021 09:59:38 -0500 Subject: [PATCH] revert "temporarily disable throwing on failure" (#1239) --- store/google/Publisher/Program.cs | 36 +++++++++++++++---------------- 1 file changed, 18 insertions(+), 18 deletions(-) diff --git a/store/google/Publisher/Program.cs b/store/google/Publisher/Program.cs index 683862a09..68cec9356 100644 --- a/store/google/Publisher/Program.cs +++ b/store/google/Publisher/Program.cs @@ -101,27 +101,27 @@ namespace Bit.Publisher { Console.WriteLine("Upload exception: {0}", progress.Exception); } - // throw new Exception("Upload failed."); + throw new Exception("Upload failed."); } } - // Console.WriteLine("Version code {0} has been uploaded.", aab.VersionCode); - // - // var trackRequest = service.Edits.Tracks.Update(new Track - // { - // TrackValue = _track, - // Releases = new List - // { - // new TrackRelease { VersionCodes = new List { aab.VersionCode }, Status = "completed" } - // } - // }, Package, edit.Id, _track); - // - // var updatedTrack = await trackRequest.ExecuteAsync(); - // Console.WriteLine("Track {0} has been updated.", updatedTrack.TrackValue); - // - // var commitRequest = service.Edits.Commit(Package, edit.Id); - // var commitEdit = await commitRequest.ExecuteAsync(); - // Console.WriteLine("App edit with id {0} has been comitted.", commitEdit.Id); + Console.WriteLine("Version code {0} has been uploaded.", aab.VersionCode); + + var trackRequest = service.Edits.Tracks.Update(new Track + { + TrackValue = _track, + Releases = new List + { + new TrackRelease { VersionCodes = new List { aab.VersionCode }, Status = "completed" } + } + }, Package, edit.Id, _track); + + var updatedTrack = await trackRequest.ExecuteAsync(); + Console.WriteLine("Track {0} has been updated.", updatedTrack.TrackValue); + + var commitRequest = service.Edits.Commit(Package, edit.Id); + var commitEdit = await commitRequest.ExecuteAsync(); + Console.WriteLine("App edit with id {0} has been comitted.", commitEdit.Id); } } }