public IQueryable <ProjectInvitation> GetCreatedProjectInvitations(int projectID) { if (!ProjectService.IsUserOwner(UserContext.AccountID)) { return(new List <ProjectInvitation>().AsQueryable()); } return(ProjectInvitations.Where(pi => pi.TargetProjectID == projectID)); }
public IQueryable <ProjectInvitation> GetProjectInvitations() { return(ProjectInvitations.Where(pi => pi.TargetUserID == UserContext.AccountID)); }