예제 #1
0
        public void SetBanned(User sender, BanStatus banStatus)
        {
            if (!sender.IsAdmin)
            {
                throw new AccessDeniedException();
            }

            BanStatus = banStatus;
        }
예제 #2
0
 public User(
     string login,
     string password,
     UserStatus status,
     BanStatus banStatus
     ) : this()
 {
     Login = login;
     SetData(password);
     Status    = status;
     BanStatus = banStatus;
 }