Fixes TryConvertTo with StringValues
This commit is contained in:
@@ -57,7 +57,9 @@ namespace Umbraco.Web.BackOffice.Authorization
|
||||
// must succeed this requirement since we cannot process it
|
||||
return Task.FromResult(true);
|
||||
}
|
||||
userIds = ids.Select(x => x.Value.TryConvertTo<int>()).Where(x => x.Success).Select(x => x.Result).ToArray();
|
||||
userIds = ids
|
||||
.Select(x => x.Value.ToString())
|
||||
.Select(x => x.TryConvertTo<int>()).Where(x => x.Success).Select(x => x.Result).ToArray();
|
||||
}
|
||||
|
||||
if (userIds.Length == 0)
|
||||
|
||||
@@ -54,7 +54,10 @@ namespace Umbraco.Web.BackOffice.Authorization
|
||||
return Task.FromResult(true);
|
||||
}
|
||||
|
||||
var intIds = ids.Select(x => x.Value.TryConvertTo<int>()).Where(x => x.Success).Select(x => x.Result).ToArray();
|
||||
var intIds = ids
|
||||
.Select(x => x.Value.ToString())
|
||||
.Select(x => x.TryConvertTo<int>()).Where(x => x.Success).Select(x => x.Result).ToArray();
|
||||
|
||||
var authHelper = new UserGroupEditorAuthorizationHelper(
|
||||
_userService,
|
||||
_contentService,
|
||||
|
||||
Reference in New Issue
Block a user