class ReviewPermissionRules {

    @PermissionRule(value = "REVIEW_APPLICATIONS", description = "Only project finance or competition admin can " +
            "see review panel applications if the competition is in the correct state.")
    public boolean reviewPanelApplications(CompetitionCompositeId competitionCompositeId, UserResource loggedInUser) {
        CompetitionResource competition = competitionRestService.getCompetitionById(competitionCompositeId.id()).getSuccess();
        return isInternalAdmin(loggedInUser) &&
                competitionHasReviewPanel(competition) &&
                competitionIsInFundersPanel(competition);
    }

}