From 0a4bb85e7755a3a90c48ad285e47c2ad27c8e2d5 Mon Sep 17 00:00:00 2001 From: Thorsten Sommer Date: Thu, 29 May 2025 21:26:20 +0200 Subject: [PATCH] Switch to use IsNullOrWhiteSpace --- app/Build/Commands/Pdfium.cs | 2 +- .../SourceCodeRules/NamingAnalyzers/LocalConstantsAnalyzer.cs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/app/Build/Commands/Pdfium.cs b/app/Build/Commands/Pdfium.cs index 23902296..12348a4b 100644 --- a/app/Build/Commands/Pdfium.cs +++ b/app/Build/Commands/Pdfium.cs @@ -48,7 +48,7 @@ public static class Pdfium // Console.Write(" deploying ..."); var library = GetLibraryPath(rid); - if (string.IsNullOrEmpty(library.Path)) + if (string.IsNullOrWhiteSpace(library.Path)) { Console.WriteLine($" failed to find the library path for {rid.ToUserFriendlyName()}"); return; diff --git a/app/SourceCodeRules/SourceCodeRules/NamingAnalyzers/LocalConstantsAnalyzer.cs b/app/SourceCodeRules/SourceCodeRules/NamingAnalyzers/LocalConstantsAnalyzer.cs index da0e130e..3c7e5b25 100644 --- a/app/SourceCodeRules/SourceCodeRules/NamingAnalyzers/LocalConstantsAnalyzer.cs +++ b/app/SourceCodeRules/SourceCodeRules/NamingAnalyzers/LocalConstantsAnalyzer.cs @@ -59,5 +59,5 @@ public sealed class LocalConstantsAnalyzer : DiagnosticAnalyzer } private static bool IsUpperCase(string name) => name.All(c => char.IsUpper(c) || char.IsDigit(c) || c == '_') && - !string.IsNullOrEmpty(name) && name.Any(char.IsLetter); + !string.IsNullOrWhiteSpace(name) && name.Any(char.IsLetter); } \ No newline at end of file