last ...
This commit is contained in:
@@ -1,6 +1,8 @@
|
||||
using System;
|
||||
using xCommons.Extensions;
|
||||
using xExceptions.Constants;
|
||||
using xCommons.Authorization;
|
||||
using xHttpService.Interfaces;
|
||||
using Microsoft.AspNetCore.Http;
|
||||
using xIdentityService.Security;
|
||||
using xIdentityService.Constants;
|
||||
@@ -12,8 +14,6 @@ using Microsoft.AspNetCore.Authorization;
|
||||
using Microsoft.Extensions.Configuration;
|
||||
using Microsoft.Extensions.DependencyInjection;
|
||||
using IdentityModel.AspNetCore.OAuth2Introspection;
|
||||
using xHttpService.Interfaces;
|
||||
using xExceptions.Constants;
|
||||
|
||||
namespace xIdentityService.DI
|
||||
{
|
||||
@@ -150,21 +150,21 @@ namespace xIdentityService.DI
|
||||
var roles = source.GetRegisteredService<IXRoleProvider>();
|
||||
var scopes = source.GetRegisteredService<IXScopeProvider>();
|
||||
var policies = source.GetRegisteredService<IXPolicyProvider>();
|
||||
var roleSync = source.GetRegisteredService<IXRoleSyncService>();
|
||||
var cache = source.GetRegisteredService<IXAuthorizationCache>();
|
||||
var scopeSync = source.GetRegisteredService<IXScopeSyncService>();
|
||||
var resolver = source.GetRegisteredService<IXRoleHierarchyResolver>();
|
||||
// var roleSync = source.GetRegisteredService<IXRoleSyncService>();
|
||||
// var scopeSync = source.GetRegisteredService<IXScopeSyncService>();
|
||||
|
||||
//
|
||||
var isValid =
|
||||
var isInvalid =
|
||||
roles.IsNull() ||
|
||||
cache.IsNull() ||
|
||||
scopes.IsNull() ||
|
||||
policies.IsNull() ||
|
||||
roleSync.IsNull() ||
|
||||
resolver.IsNull() ||
|
||||
scopeSync.IsNull();
|
||||
if (!isValid)
|
||||
resolver.IsNull();
|
||||
// roleSync.IsNull() ||
|
||||
// scopeSync.IsNull();
|
||||
if (isInvalid)
|
||||
{
|
||||
XException.InvalidConfiguration.Throw();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user