Skip to content

Commit

Permalink
Merge pull request #8 from maiconheck/feature/guard-null-class-constr…
Browse files Browse the repository at this point in the history
…aint-removed

feature(Guard.Null): 'where T : class' generic constraint removed to increase the parameter types allowed
  • Loading branch information
maiconheck authored Jan 23, 2024
2 parents cc82476 + f6bea91 commit b708865
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions src/Krafted/Directory.build.props
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
<Project>
<PropertyGroup>
<Authors>Maicon Heck</Authors>
<Version>5.0.0</Version>
<PackageVersion>5.0.0</PackageVersion>
<Version>5.1.0</Version>
<PackageVersion>5.1.0</PackageVersion>
<Product>Krafted</Product>
<ProductName>Krafted</ProductName>
<PackageId>$(MSBuildProjectName)</PackageId>
Expand Down
2 changes: 1 addition & 1 deletion src/Krafted/Krafted.Guards/GuardClauses/Guard.Null.cs
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ public partial class Guard
/// <param name="parameterName">The name of the parameter with which <paramref name="parameter"/> corresponds. If you omit this parameter, the name of parameter is used.</param>
/// <exception cref="ArgumentNullException"><paramref name="parameter"/> is <c>null</c>.</exception>
/// <returns>The guard.</returns>
public Guard Null<T>([NotNull] T? parameter, string message = "", [CallerArgumentExpression("parameter")] string? parameterName = null) where T : class
public Guard Null<T>([NotNull] T? parameter, string message = "", [CallerArgumentExpression("parameter")] string? parameterName = null)
{
Guard.Against.NullOrWhiteSpace(parameterName!);

Expand Down

0 comments on commit b708865

Please sign in to comment.