original_string: protected function process_actions($quiz, $cm, $currentgroup, \core\dml\sql_join $groupstudentsjoins,
              \core\dml\sql_join $allowedjoins, $redirecturl) {
          if (empty($currentgroup) || $this->hasgroupstudents) {
              if (optional_param('delete', 0, PARAM_BOOL) && confirm_sesskey()) {
                  if ($attemptids = optional_param_array('attemptid', array(), PARAM_INT)) {
                      require_capability('mod/quiz:deleteattempts', $this->context);
                      $this->delete_selected_attempts($quiz, $cm, $attemptids, $allowedjoins);
                      redirect($redirecturl);
                  }
              }
          }
      }
code: protected function process_actions($quiz, $cm, $currentgroup, \core\dml\sql_join $groupstudentsjoins,
              \core\dml\sql_join $allowedjoins, $redirecturl) {
          if (empty($currentgroup) || $this->hasgroupstudents) {
              if (optional_param('delete', 0, PARAM_BOOL) && confirm_sesskey()) {
                  if ($attemptids = optional_param_array('attemptid', array(), PARAM_INT)) {
                      require_capability('mod/quiz:deleteattempts', $this->context);
                      $this->delete_selected_attempts($quiz, $cm, $attemptids, $allowedjoins);
                      redirect($redirecturl);
                  }
              }
          }
      }
code_tokens: protected function process_actions ( $ quiz , $ cm , $ currentgroup , \ core \ dml \ sql_join $ groupstudentsjoins , \ core \ dml \ sql_join $ allowedjoins , $ redirecturl ) { if ( empty ( $ currentgroup ) || $ this -> hasgroupstudents ) { if ( optional_param ( 'delete' , 0 , PARAM_BOOL ) && confirm_sesskey ( ) ) { if ( $ attemptids = optional_param_array ( 'attemptid' , array ( ) , PARAM_INT ) ) { require_capability ( 'mod/quiz:deleteattempts' , $ this -> context ) ; $ this -> delete_selected_attempts ( $ quiz , $ cm , $ attemptids , $ allowedjoins ) ; redirect ( $ redirecturl ) ; } } } }
docstring: Process any submitted actions.
  @param object $quiz the quiz settings.
  @param object $cm the cm object for the quiz.
  @param int $currentgroup the currently selected group.
  @param \core\dml\sql_join $groupstudentsjoins (joins, wheres, params) the students in the current group.
  @param \core\dml\sql_join $allowedjoins (joins, wheres, params) the users whose attempt this user is allowed to modify.
  @param moodle_url $redirecturl where to redircet to after a successful action.
docstring_tokens: Process any submitted actions .