mirror of
https://github.com/goatcorp/Dalamud.git
synced 2025-12-12 18:27:23 +01:00
fix: only include first line of exception in troubleshooting context
This commit is contained in:
parent
9c30a36cd0
commit
3059960fab
1 changed files with 4 additions and 2 deletions
|
|
@ -33,11 +33,13 @@ namespace Dalamud.Support
|
||||||
{
|
{
|
||||||
LastException = exception;
|
LastException = exception;
|
||||||
|
|
||||||
|
var fixedContext = context?.Split(new []{'\r', '\n'}, StringSplitOptions.RemoveEmptyEntries).FirstOrDefault();
|
||||||
|
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
var payload = new ExceptionPayload
|
var payload = new ExceptionPayload
|
||||||
{
|
{
|
||||||
Context = context,
|
Context = fixedContext,
|
||||||
When = DateTime.Now,
|
When = DateTime.Now,
|
||||||
Info = exception.ToString(),
|
Info = exception.ToString(),
|
||||||
};
|
};
|
||||||
|
|
@ -92,7 +94,7 @@ namespace Dalamud.Support
|
||||||
|
|
||||||
public string Info { get; set; }
|
public string Info { get; set; }
|
||||||
|
|
||||||
public string Context { get; set; }
|
public string? Context { get; set; }
|
||||||
}
|
}
|
||||||
|
|
||||||
private class TroubleshootingPayload
|
private class TroubleshootingPayload
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue