mirror of
https://github.com/microsoft/PowerToys.git
synced 2026-04-06 03:07:04 +02:00
[NetAnalyzers]CA1031 suppressions cleanup (#18706)
This commit is contained in:
committed by
GitHub
parent
33072c7ee3
commit
b33bc2ecd0
@@ -137,9 +137,7 @@ namespace Microsoft.PowerToys.Run.Plugin.WindowsTerminal
|
||||
{
|
||||
appManager.ActivateApplication(id, queryArguments, noFlags, out var unusedPid);
|
||||
}
|
||||
#pragma warning disable CA1031 // Do not catch general exception types
|
||||
catch (Exception ex)
|
||||
#pragma warning restore CA1031 // Do not catch general exception types
|
||||
{
|
||||
var name = "Plugin: " + Resources.plugin_name;
|
||||
var message = Resources.run_terminal_failed;
|
||||
@@ -155,9 +153,7 @@ namespace Microsoft.PowerToys.Run.Plugin.WindowsTerminal
|
||||
string path = "shell:AppsFolder\\" + id;
|
||||
Helper.OpenInShell(path, TerminalHelper.GetArguments(profile, _openNewTab), runAs: Helper.ShellRunAsType.Administrator);
|
||||
}
|
||||
#pragma warning disable CA1031 // Do not catch general exception types
|
||||
catch (Exception ex)
|
||||
#pragma warning restore CA1031 // Do not catch general exception types
|
||||
{
|
||||
var name = "Plugin: " + Resources.plugin_name;
|
||||
var message = Resources.run_terminal_failed;
|
||||
|
||||
Reference in New Issue
Block a user