mirror of
https://github.com/Prowlarr/Prowlarr.git
synced 2025-09-27 04:21:27 +02:00
Updated Exceptron driver to 0.1.0.30 to add support for severity.
This commit is contained in:
@@ -69,7 +69,24 @@ namespace NzbDrone.Common
|
||||
exceptionData.Message = logEvent.FormattedMessage;
|
||||
exceptionData.UserId = EnvironmentProvider.UGuid.ToString().Replace("-", string.Empty);
|
||||
|
||||
return ExceptronDriver.SubmitException(exceptionData);
|
||||
if (logEvent.Level <= LogLevel.Info)
|
||||
{
|
||||
exceptionData.Severity = ExceptionSeverity.None;
|
||||
}
|
||||
else if (logEvent.Level <= LogLevel.Warn)
|
||||
{
|
||||
exceptionData.Severity = ExceptionSeverity.Warning;
|
||||
}
|
||||
else if (logEvent.Level <= LogLevel.Error)
|
||||
{
|
||||
exceptionData.Severity = ExceptionSeverity.Error;
|
||||
}
|
||||
else if (logEvent.Level <= LogLevel.Fatal)
|
||||
{
|
||||
exceptionData.Severity = ExceptionSeverity.Fatal;
|
||||
}
|
||||
|
||||
return ExceptronDriver.SubmitException(exceptionData).RefId;
|
||||
}
|
||||
catch (Exception e)
|
||||
{
|
||||
|
Reference in New Issue
Block a user