Hi,
we are facing an issue trying to set a term in a taxonomy field for a file...

That term contains a comma character, ... taking a look to the code, the class ListItemUtilities.cs is splitting the values by ',' or ';'.
Since the term label contains a comma, the term is not found and then the code is giving an exception.


I think that we only should split the values by ';' before doing the foreach, but for compatibility issues, I will send a PR checking if the taxonomyItem is null or not before trying to add it to the terms List, so that way we avoid the Exception.
Doing it that way, it works properly for me, because in the next iteration, arrayItem will have the following value "Tools & Industrial|8a72d73c-2157-4cef-8ba9-d7415f4cf226" and the method GetTaxonomyItemByPath, it will find the term properly by the Guid.

Hi,

we are facing an issue trying to set a term in a taxonomy field for a file...
That term contains a comma character, ... taking a look to the code, the class ListItemUtilities.cs is splitting the values by ',' or ';'.

Since the term label contains a comma, the term is not found and then the code is giving an exception.
I think that we only should split the values by ';' before doing the foreach, but for compatibility issues, I will send a PR checking if the taxonomyItem is null or not before trying to add it to the terms List, so that way we avoid the Exception.
Doing it that way, it works properly for me, because in the next iteration, arrayItem will have the following value "Tools & Industrial|8a72d73c-2157-4cef-8ba9-d7415f4cf226" and the method GetTaxonomyItemByPath, it will find the term properly by the Guid.
