diff options
Diffstat (limited to 'src/SMAPI.Toolkit/Serialization/Models')
3 files changed, 6 insertions, 0 deletions
diff --git a/src/SMAPI.Toolkit/Serialization/Models/Manifest.cs b/src/SMAPI.Toolkit/Serialization/Models/Manifest.cs index 3ab5edfb..01010602 100644 --- a/src/SMAPI.Toolkit/Serialization/Models/Manifest.cs +++ b/src/SMAPI.Toolkit/Serialization/Models/Manifest.cs @@ -115,7 +115,9 @@ namespace StardewModdingAPI.Toolkit.Serialization.Models *********/ /// <summary>Normalize whitespace in a raw string.</summary> /// <param name="input">The input to strip.</param> +#if NET5_0_OR_GREATER [return: NotNullIfNotNull("input")] +#endif private string? NormalizeWhitespace(string? input) { return input diff --git a/src/SMAPI.Toolkit/Serialization/Models/ManifestContentPackFor.cs b/src/SMAPI.Toolkit/Serialization/Models/ManifestContentPackFor.cs index dcdbcf74..f7dc8aa8 100644 --- a/src/SMAPI.Toolkit/Serialization/Models/ManifestContentPackFor.cs +++ b/src/SMAPI.Toolkit/Serialization/Models/ManifestContentPackFor.cs @@ -33,7 +33,9 @@ namespace StardewModdingAPI.Toolkit.Serialization.Models *********/ /// <summary>Normalize whitespace in a raw string.</summary> /// <param name="input">The input to strip.</param> +#if NET5_0_OR_GREATER [return: NotNullIfNotNull("input")] +#endif private string? NormalizeWhitespace(string? input) { return input?.Trim(); diff --git a/src/SMAPI.Toolkit/Serialization/Models/ManifestDependency.cs b/src/SMAPI.Toolkit/Serialization/Models/ManifestDependency.cs index 5d1b73b1..fa254ea7 100644 --- a/src/SMAPI.Toolkit/Serialization/Models/ManifestDependency.cs +++ b/src/SMAPI.Toolkit/Serialization/Models/ManifestDependency.cs @@ -54,7 +54,9 @@ namespace StardewModdingAPI.Toolkit.Serialization.Models *********/ /// <summary>Normalize whitespace in a raw string.</summary> /// <param name="input">The input to strip.</param> +#if NET5_0_OR_GREATER [return: NotNullIfNotNull("input")] +#endif private string? NormalizeWhitespace(string? input) { return input?.Trim(); |