You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Description: When NullOrEmpty or NullOrWhiteSpace are used, a custom message can be set. However, if the input is null, the message contained within the exception thrown by the mentioned Guard clauses will be different than one set as the clause parameter.
Steps to Reproduce:
Use Ardalis.GuardClauses 3.3.0 NuGet Package.
Ensure that Guard.Against.NullOrEmpty is invoked with the input parameter being null, parameterName parameter being "parameterName" and custom message set (e.g. "Some Test Message").
Examine the exception thrown by the Guard clause and check the Message property.
The Message property will be "Value cannot be null. (Parameter 'parameterName')" instead of the message set previously.
The text was updated successfully, but these errors were encountered:
Description: When NullOrEmpty or NullOrWhiteSpace are used, a custom message can be set. However, if the input is null, the message contained within the exception thrown by the mentioned Guard clauses will be different than one set as the clause parameter.
Steps to Reproduce:
input
parameter being null,parameterName
parameter being "parameterName" and custommessage
set (e.g. "Some Test Message").Message
property.Message
property will be "Value cannot be null. (Parameter 'parameterName')" instead of the message set previously.The text was updated successfully, but these errors were encountered: