DocSpace-buildtools/common/ASC.Common/ArgumentNullExceptionExtension.cs
2022-03-09 20:15:51 +03:00

13 lines
343 B
C#

namespace System;
public static class ArgumentNullOrEmptyException
{
public static void ThrowIfNullOrEmpty(string argument, [CallerArgumentExpression("argument")] string? paramName = null)
{
if (string.IsNullOrEmpty(argument))
{
throw new ArgumentNullException(paramName);
}
}
}