Refactor "Routing/Builder" methods pre conditions#41783
Conversation
…ArgumentNullException ThrowIfNull
…onditions => ArgumentNullException ThrowIfNull
…ions => ArgumentNullException ThrowIfNull
…ntNullException ThrowIfNull
…nditions => ArgumentNullException ThrowIfNull
| { | ||
| throw new ArgumentNullException(nameof(items)); | ||
| } | ||
| ArgumentNullException.ThrowIfNull(builder, nameof(builder)); |
There was a problem hiding this comment.
Why is nameof needed? Isn't it inferred by default from the expression passed in?
There was a problem hiding this comment.
It just got fixed
…names from ArgumentNullException
|
Hi @mottaghipour. It looks like you just commented on a closed PR. The team will most probably miss it. If you'd like to bring something important up to their attention, consider filing a new issue and add enough details to build context. |
|
@mottaghipour Why did you close this PR? s there some reason you do not want us to merge this change? |
|
@halter73 After pulling, I read the contributing guidelines and in this part, I realized that my work was wrong, refactoring here is bad for merge! |
|
Generally, we like people to file an issue first. Mostly it's so people don't waste time on PRs that we won't merge. In this particular case it's fine though. Thanks for your contribution! |
Refactor "Routing/Builder" methods pre conditions
Replace block conditions with "ArgumentNullException.ThrowIfNull(...);"