Beispiel #1
0
        public UserStatus AddUser(User user)
        {
            if (Records.FirstOrDefault(u => u.Username == user.Username) != null)
            {
                return(UserStatus.UserExists(user.Username));
            }

            Insert(user);
            SaveChanges();

            return(UserStatus.OK(user));
        }