1 redirect.admin.inc redirect_list_form_operations_validate($form, &$form_state)

Validate redirect_list_form form submissions.

Check if any redirects have been selected to perform the chosen 'Update option' on.

File

core/modules/redirect/redirect.admin.inc, line 235
Administrative page callbacks for the Redirect module.

Code

function redirect_list_form_operations_validate($form, &$form_state) {
  // Error if there are no redirects selected.
  if (!is_array($form_state['values']['rids']) || !count(array_filter($form_state['values']['rids']))) {
    form_set_error('', t('No redirects selected.'));
  }
}