S
shapper
Hello,
I am getting a Post with its Tags.
When there is not Tags what should I do?
Not initialize the tags and then Post.Tags will be null.
Or initialize the tags and then Post.Tags.Count is 0 but Post.Tags is
not null.
Linq query initializes the tags.
ASP.NET Mvc model update does not initializes it when the text box has
no content.
Basically I have different behaviors ...
.... for everything to work (validation, binding) I am trying to choose
one approach.
If not the code gets a little bit confusing because I never now if it
is coming null or Count=0.
I am trying to decide which approach should I use ...
Thanks,
Miguel
I am getting a Post with its Tags.
When there is not Tags what should I do?
Not initialize the tags and then Post.Tags will be null.
Or initialize the tags and then Post.Tags.Count is 0 but Post.Tags is
not null.
Linq query initializes the tags.
ASP.NET Mvc model update does not initializes it when the text box has
no content.
Basically I have different behaviors ...
.... for everything to work (validation, binding) I am trying to choose
one approach.
If not the code gets a little bit confusing because I never now if it
is coming null or Count=0.
I am trying to decide which approach should I use ...
Thanks,
Miguel