CommunityToolkit / dotnet

.NET Community Toolkit is a collection of helpers and APIs that work for all .NET developers and are agnostic of any specific UI platform. The toolkit is maintained and published by Microsoft, and part of the .NET Foundation.
https://docs.microsoft.com/dotnet/communitytoolkit/?WT.mc_id=dotnet-0000-bramin
Other
2.8k stars 277 forks source link

Typo in Guard.ThrowHelper.ThrowArgumentNullExceptionForIsNotNull #862

Open Benna96 opened 2 months ago

Benna96 commented 2 months ago

Describe the bug

There's a minor typo in Guard.ThrowHelper.ThrowArgumentNullExceptionForIsNotNull, an extra ).

Regression

No response

Steps to reproduce

1. Paste the following code:

object? foo = null;
Guard.IsNotNull(foo);

2. Run the code.
3. Observe that a `NullArgumentException` with the message is `Parameter "foo" (System.Object) must be not null).` is thrown.

Expected behavior

A NullArgumentException with the message Parameter "foo" (System.Object) must be not null. is thrown, without the extra ) at the end.

Screenshots

image

IDE and version

VS 2022

IDE version

No response

Nuget packages

Nuget package version(s)

8.2.2

Additional context

No response

Help us help you

Yes, I'd like to be assigned to work on this item