private bool IsUserAuthorizedToEditComment(Commentary comment) { bool isAdmin = this.User.IsInRole("Admin"); bool isAuthor = comment.IsAuthorOfComment(this.User.Identity.Name); return(isAdmin || isAuthor); }
private bool IsUserAuthorizedToEditComment(Commentary comment) { bool isAdmin = this.User.IsInRole("Admin"); bool isAuthor = comment.IsAuthorOfComment(this.User.Identity.Name); return(isAdmin || isAuthor); }