[NetAnalyzers]CA1031 suppressions cleanup (#18706)

This commit is contained in:
Davide Giacometti
2022-06-12 15:11:52 +02:00
committed by GitHub
parent 33072c7ee3
commit b33bc2ecd0
54 changed files with 0 additions and 143 deletions

View File

@@ -70,9 +70,7 @@ namespace ImageResizer.Models
{
Execute(file);
}
#pragma warning disable CA1031 // Do not catch general exception types
catch (Exception ex)
#pragma warning restore CA1031 // Do not catch general exception types
{
errors.Add(new ResizeError { File = _fileSystem.Path.GetFileName(file), Error = ex.Message });
}

View File

@@ -258,9 +258,7 @@ namespace ImageResizer.Models
return true;
}
#pragma warning disable CA1031 // Do not catch general exception types
catch (Exception)
#pragma warning restore CA1031 // Do not catch general exception types
{
return false;
}