mirror of
https://github.com/microsoft/PowerToys
synced 2025-09-07 18:05:12 +00:00
[NetAnalyzers]CA1031 suppressions cleanup (#18706)
This commit is contained in:
committed by
GitHub
parent
33072c7ee3
commit
b33bc2ecd0
@@ -780,9 +780,7 @@ namespace PowerLauncher.ViewModel
|
||||
_hotkeyHandle = HotkeyManager.RegisterHotkey(hotkey, action);
|
||||
}
|
||||
}
|
||||
#pragma warning disable CA1031 // Do not catch general exception types
|
||||
catch (Exception)
|
||||
#pragma warning restore CA1031 // Do not catch general exception types
|
||||
{
|
||||
string errorMsg = string.Format(CultureInfo.InvariantCulture, Properties.Resources.registerHotkeyFailed, hotkeyStr);
|
||||
MessageBox.Show(errorMsg);
|
||||
|
Reference in New Issue
Block a user