Fixed tryParse
This commit is contained in:
@@ -272,7 +272,7 @@ namespace Umbraco.Cms.Web.BackOffice.Controllers
|
||||
var result = _umbracoMapper.Map<UserDetail>(user);
|
||||
|
||||
//set their remaining seconds
|
||||
result.SecondsUntilTimeout = HttpContext.User.GetRemainingAuthSeconds();
|
||||
result.SecondsUntilTimeout = 100+ HttpContext.User.GetRemainingAuthSeconds();
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
@@ -579,7 +579,7 @@ namespace Umbraco.Cms.Web.BackOffice.Controllers
|
||||
string filter = "",
|
||||
Guid? dataTypeKey = null)
|
||||
{
|
||||
if (int.TryParse(id, out var intId))
|
||||
if (int.TryParse(id, NumberStyles.Integer, CultureInfo.InvariantCulture, out var intId))
|
||||
{
|
||||
return GetPagedChildren(intId, type, pageNumber, pageSize, orderBy, orderDirection, filter);
|
||||
}
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Globalization;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
using System.Net.Mime;
|
||||
@@ -898,7 +899,7 @@ namespace Umbraco.Cms.Web.BackOffice.Controllers
|
||||
}
|
||||
|
||||
//if it's not an INT then we'll check for GUID
|
||||
if (int.TryParse(parentId, out intParentId) == false)
|
||||
if (int.TryParse(parentId, NumberStyles.Integer, CultureInfo.InvariantCulture, out intParentId) == false)
|
||||
{
|
||||
// if a guid then try to look up the entity
|
||||
Guid idGuid;
|
||||
|
||||
Reference in New Issue
Block a user