You are here

function nodejs_notify_settings_form_validate in Node.js integration 6

Same name and namespace in other branches
  1. 7 nodejs_notify/nodejs_notify.module \nodejs_notify_settings_form_validate()

Form Validation

File

nodejs_notify/nodejs_notify.module, line 87

Code

function nodejs_notify_settings_form_validate($form, &$form_state) {
  if (!preg_match('/^\\d+$/', $form_state['values']['notification_lifetime'])) {
    form_set_error('notification_lifetime', t('The notification lifetime must be a number.'));
  }
}