Hi Steve!

Thanks for taking the time to read my article. It’s much appreciated!

The collection initialization syntax uses the Add() method behind the scenes. So, if you pass in null, it’ll just return and exit the method.

I did do unit tests before putting this up :)

Sure, extension methods are definitely a way to go. They do however serve a different purpose than the one I’m describing here.

Tech writer with +1M views. Sharing my opinion and what I learn. .NET backend engineer in FinTech. New YouTube Channel https://bit.ly/3vxqNHj

Tech writer with +1M views. Sharing my opinion and what I learn. .NET backend engineer in FinTech. New YouTube Channel https://bit.ly/3vxqNHj