private bool uniqueMail() { int counter = 0; registeredDbEntities entities = new registeredDbEntities(); List <Profile> profiles = rep.Get(); for (int i = 0; i < profiles.Count; i++) { if (profile.mail != profiles[i].mail) { counter++; } else { return(false); //for not continuing working in for cycle; } } if (counter == profiles.Count) { return(true); } else { return(false); } }
public List <Profile> Get() { return(rep.Get()); }