fix: add CultureInfo.InvariantCulture to int.Parse

Fix issue where different Culture some times makes int.Parse thrown an `System.FormatException: 'Input string was not in a correct format.' `

Closes: U4-10596
This commit is contained in:
Rune Antonsen
2017-11-23 15:12:01 +01:00
parent 8d14a3ef2c
commit fe67a09ccb

View File

@@ -251,7 +251,7 @@ namespace Umbraco.Web.PublishedCache.XmlPublishedCache
// move to parent node
e = (XmlElement) e.ParentNode;
id = int.Parse(e.GetAttribute("id"));
id = int.Parse(e.GetAttribute("id"), CultureInfo.InvariantCulture);
hasDomains = id != -1 && domainHelper.NodeHasDomains(id);
}