diff --git a/src/Umbraco.Web/Security/WebSecurity.cs b/src/Umbraco.Web/Security/WebSecurity.cs index 3cc853dfe0..7bd3aa4475 100644 --- a/src/Umbraco.Web/Security/WebSecurity.cs +++ b/src/Umbraco.Web/Security/WebSecurity.cs @@ -250,7 +250,7 @@ namespace Umbraco.Web.Security var identity = _httpContext.GetCurrentIdentity(); if (identity == null) return -1; - return (int)identity.Id; + return Convert.ToInt32(identity.Id); } /// diff --git a/src/umbraco.businesslogic/BasePages/BasePage.cs b/src/umbraco.businesslogic/BasePages/BasePage.cs index 0512319bdb..c0171d7d9a 100644 --- a/src/umbraco.businesslogic/BasePages/BasePage.cs +++ b/src/umbraco.businesslogic/BasePages/BasePage.cs @@ -184,7 +184,7 @@ namespace umbraco.BasePages var identity = HttpContext.Current.GetCurrentIdentity(); if (identity == null) return -1; - return (int)identity.Id; + return Convert.ToInt32(identity.Id); } // Added by NH to use with webservices authentications