Example #1
0
        public override async Task ValidateAsync(CookieValidatePrincipalContext context)
        {
            var tenant = await TenantConfigurationProvider.GetAsync(saveResolveResult : false);

            using (CurrentTenant.Change(tenant?.Id, tenant?.Name))
            {
                await base.ValidateAsync(context);
            }
        }
Example #2
0
        public override async Task ValidateAsync(CookieValidatePrincipalContext context)
        {
            TenantConfiguration tenant = null;

            try
            {
                tenant = await TenantConfigurationProvider.GetAsync(saveResolveResult : false);
            }
            catch (Exception e)
            {
                Logger.LogException(e);
            }

            using (CurrentTenant.Change(tenant?.Id, tenant?.Name))
            {
                await base.ValidateAsync(context);
            }
        }