From 92d60a6db8d5f9c472c3e2784b1cdcd8154f75c3 Mon Sep 17 00:00:00 2001 From: Oliver Booth Date: Mon, 19 Jul 2021 11:38:24 +0100 Subject: [PATCH] (#42) Use NRT for AddNullIf__ --- X10D/src/StringExtensions/StringExtensions.cs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/X10D/src/StringExtensions/StringExtensions.cs b/X10D/src/StringExtensions/StringExtensions.cs index 72998e6..d0e8e80 100644 --- a/X10D/src/StringExtensions/StringExtensions.cs +++ b/X10D/src/StringExtensions/StringExtensions.cs @@ -1,4 +1,4 @@ -using System; +using System; using System.Collections.Generic; using System.Linq; using System.Text; @@ -18,7 +18,7 @@ namespace X10D /// if is or equal to /// , or otherwise. /// - public static string? AsNullIfEmpty(this string value) + public static string? AsNullIfEmpty(this string? value) { return string.IsNullOrEmpty(value) ? null : value; } @@ -32,7 +32,7 @@ namespace X10D /// if is or equal to /// or is composed of only whitespace characters, or otherwise. /// - public static string? AsNullIfWhiteSpace(this string value) + public static string? AsNullIfWhiteSpace(this string? value) { return string.IsNullOrWhiteSpace(value) ? null : value; }