Source:
protected ActionResult execute() throws EntityDoesNotExistException { String courseIdForNewSession = getRequestParamValue(Const.ParamsNames.COURSE_ID); String feedbackSessionNameForSessionList = getRequestParamValue(Const.ParamsNames.FEEDBACK_SESSION_NAME); String isUsingAjax = getRequestParamValue(Const.ParamsNames.IS_USING_AJAX); new GateKeeper().verifyInstructorPrivileges(account); if (courseIdForNewSession != null) { new GateKeeper().verifyAccessible( logic.getInstructorForGoogleId(courseIdForNewSession, account.googleId), logic.getCourse(courseIdForNewSession), Const.ParamsNames.INSTRUCTOR_PERMISSION_MODIFY_SESSION); } InstructorFeedbacksPageData data = new InstructorFeedbacksPageData(account); data.isUsingAjax = isUsingAjax != null; data.courseIdForNewSession = courseIdForNewSession; data.feedbackSessionNameForSessionList = feedbackSessionNameForSessionList; data.newFeedbackSession = null; boolean omitArchived = true; data.instructors = loadCourseInstructorMap(omitArchived); List<InstructorAttributes> instructorList = new ArrayList<InstructorAttributes>(data.instructors.values()); data.courses = loadCoursesList(instructorList); if (data.courses.isEmpty()) { statusToUser.add(Const.StatusMessages.COURSE_EMPTY_IN_EVALUATION .replace("${user}", "?user="+account.googleId)); } if(data.courses.isEmpty() || !data.isUsingAjax) { data.existingFeedbackSessions = new ArrayList<FeedbackSessionAttributes>(); } else { data.existingFeedbackSessions = loadFeedbackSessionsList(instructorList); if (data.existingFeedbackSessions.isEmpty()) { statusToUser.add(Const.StatusMessages.EVALUATION_EMPTY); } } FeedbackSessionAttributes.sortFeedbackSessionsByCreationTimeDescending(data.existingFeedbackSessions); statusToAdmin = "Number of feedback sessions: " + data.existingFeedbackSessions.size(); data.getCourseIdOptions(); return createShowPageResult(Const.ViewURIs.INSTRUCTOR_FEEDBACKS, data); }

Target:
protected ActionResult execute() throws EntityDoesNotExistException { String courseIdForNewSession = getRequestParamValue(Const.ParamsNames.COURSE_ID); String feedbackSessionNameForSessionList = getRequestParamValue(Const.ParamsNames.FEEDBACK_SESSION_NAME); String isUsingAjax = getRequestParamValue(Const.ParamsNames.IS_USING_AJAX); new GateKeeper().verifyInstructorPrivileges(account); if (courseIdForNewSession != null) { new GateKeeper().verifyAccessible( logic.getInstructorForGoogleId(courseIdForNewSession, account.googleId), logic.getCourse(courseIdForNewSession), Const.ParamsNames.INSTRUCTOR_PERMISSION_MODIFY_SESSION); } InstructorFeedbacksPageData data = new InstructorFeedbacksPageData(account); data.isUsingAjax = (isUsingAjax != null); data.courseIdForNewSession = courseIdForNewSession; data.feedbackSessionNameForSessionList = feedbackSessionNameForSessionList; data.newFeedbackSession = null; boolean omitArchived = true; data.instructors = loadCourseInstructorMap(omitArchived); List<InstructorAttributes> instructorList = new ArrayList<InstructorAttributes>(data.instructors.values()); data.courses = loadCoursesList(instructorList); if (data.courses.isEmpty()) { statusToUser.add(Const.StatusMessages.COURSE_EMPTY_IN_EVALUATION .replace("${user}", "?user=" + account.googleId)); } if (data.courses.isEmpty() || !data.isUsingAjax) { data.existingFeedbackSessions = new ArrayList<FeedbackSessionAttributes>(); } else { data.existingFeedbackSessions = loadFeedbackSessionsList(instructorList); if (data.existingFeedbackSessions.isEmpty()) { statusToUser.add(Const.StatusMessages.EVALUATION_EMPTY); } } FeedbackSessionAttributes.sortFeedbackSessionsByCreationTimeDescending(data.existingFeedbackSessions); statusToAdmin = "Number of feedback sessions: " + data.existingFeedbackSessions.size(); data.getCourseIdOptions(); return createShowPageResult(Const.ViewURIs.INSTRUCTOR_FEEDBACKS, data); }