Affecto.IdentityManagement.Store.EntityFramework.Queries.OrganizationExistsQuery.Execute C# (CSharp) Method

Execute() public method

public Execute ( string name ) : bool
name string
return bool
        public bool Execute(string name)
        {
            name = name.ToLower();
            return organizations.Any(o => o.Name.ToLower() == name);
        }

Usage Example

        public bool OrganizationExists(string name)
        {
            var query = new OrganizationExistsQuery(dbContext.Organizations);

            return query.Execute(name);
        }
OrganizationExistsQuery