Skip to content

Commit

Permalink
added app version to message of unhandled exception
Browse files Browse the repository at this point in the history
  • Loading branch information
cadon committed Dec 22, 2021
1 parent e12621a commit 5540199
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions ARKBreedingStats/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -62,9 +62,8 @@ private static void UnhandledExceptionHandler(object sender, UnhandledExceptionE
{
if (System.Diagnostics.Debugger.IsAttached) throw e;
string message = e.Message
+ "\n\nException type: " + e.GetType()
+ "\n\nException in " + e.Source
+ "\n\nMethod throwing the error: " + e.TargetSite.DeclaringType.FullName + "." + e.TargetSite.Name
+ "\n\n" + e.GetType() + " in " + e.Source + " (" + Utils.ApplicationNameVersion + ")"
+ "\n\nMethod throwing the error: " + e.TargetSite.DeclaringType?.FullName + "." + e.TargetSite.Name
+ "\n\nStackTrace:\n" + e.StackTrace
+ (e.InnerException != null ? "\n\nInner Exception:\n" + e.InnerException.Message : string.Empty)
;
Expand Down

0 comments on commit 5540199

Please sign in to comment.