Skip to content

Commit

Permalink
- removed exception message when a hero is added whose portrait is no…
Browse files Browse the repository at this point in the history
…t available on epicsevendb.com
  • Loading branch information
Zarroc2762 committed Mar 3, 2020
1 parent fd74471 commit 9e19b5f
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions E7 Gear Optimizer/Hero.cs
Original file line number Diff line number Diff line change
Expand Up @@ -117,6 +117,18 @@ private Image getPortrait(string name)
}
}
}
catch (WebException ex)
{
if (ex.Status != WebExceptionStatus.ProtocolError)
{
MessageBox.Show(ex.Message);
}
else if (((HttpWebResponse)ex.Response).StatusCode != HttpStatusCode.NotFound)
{
MessageBox.Show(ex.Message);
}
portrait = Util.error;
}
catch (Exception ex)
{
MessageBox.Show(ex.Message);
Expand Down

0 comments on commit 9e19b5f

Please # to comment.