You are here

function notifications_send_intervals_form_validate in Notifications 6.3

Same name and namespace in other branches
  1. 6.4 notifications.admin.inc \notifications_send_intervals_form_validate()
  2. 6.2 notifications.admin.inc \notifications_send_intervals_form_validate()

Form validate for time intervals

File

./notifications.admin.inc, line 214

Code

function notifications_send_intervals_form_validate($form, &$form_state) {

  // Check the default is a valid one, not one to be deleted
  $default = $form_state['values']['default'];
  if (empty($form_state['values']['intervals'][$default]['unit']) || empty($form_state['values']['intervals'][$default]['name'])) {
    form_set_error('default', t('Invalid default send interval.'));
  }
}