mirror of
https://github.com/microsoft/PowerToys.git
synced 2026-04-07 11:46:30 +02:00
Remove some useless code for error reporting
This commit is contained in:
@@ -6,6 +6,7 @@ using System.Text;
|
||||
using System.Linq;
|
||||
using System.Windows;
|
||||
using System.Windows.Documents;
|
||||
using Wox.Helper;
|
||||
using Wox.Infrastructure;
|
||||
using Wox.Infrastructure.Logger;
|
||||
|
||||
@@ -26,18 +27,13 @@ namespace Wox
|
||||
var directory = new DirectoryInfo(path);
|
||||
var log = directory.GetFiles().OrderByDescending(f => f.LastWriteTime).First();
|
||||
|
||||
var paragraph = Hyperlink("Please open new issue in: " , Constant.Issue);
|
||||
var paragraph = Hyperlink("Please open new issue in: ", Constant.Issue);
|
||||
paragraph.Inlines.Add($"1. upload log file: {log.FullName}\n");
|
||||
paragraph.Inlines.Add($"2. copy below exception message");
|
||||
ErrorTextbox.Document.Blocks.Add(paragraph);
|
||||
|
||||
StringBuilder content = new StringBuilder();
|
||||
content.AppendLine($"Wox version: {Constant.Version}");
|
||||
content.AppendLine($"OS Version: {Environment.OSVersion.VersionString}");
|
||||
content.AppendLine($"IntPtr Length: {IntPtr.Size}");
|
||||
content.AppendLine($"x64: {Environment.Is64BitOperatingSystem}");
|
||||
content.AppendLine($"Python Path: {Constant.PythonPath}");
|
||||
content.AppendLine($"Everything SDK Path: {Constant.EverythingSDKPath}");
|
||||
content.AppendLine(ErrorReporting.RuntimeInfo());
|
||||
content.AppendLine($"Date: {DateTime.Now.ToString(CultureInfo.InvariantCulture)}");
|
||||
content.AppendLine("Exception:");
|
||||
content.AppendLine(exception.Source);
|
||||
@@ -54,7 +50,7 @@ namespace Wox
|
||||
var paragraph = new Paragraph();
|
||||
paragraph.Margin = new Thickness(0);
|
||||
|
||||
var link = new Hyperlink {IsEnabled = true};
|
||||
var link = new Hyperlink { IsEnabled = true };
|
||||
link.Inlines.Add(url);
|
||||
link.NavigateUri = new Uri(url);
|
||||
link.RequestNavigate += (s, e) => Process.Start(e.Uri.ToString());
|
||||
|
||||
Reference in New Issue
Block a user