function fastly_setup_form_validate in Fastly 7
Same name and namespace in other branches
- 7.2 fastly.admin.inc \fastly_setup_form_validate()
Implements hook_form_validate().
File
- ./
fastly.admin.inc, line 292 - Administrative forms for Fastly module.
Code
function fastly_setup_form_validate($form, &$form_state) {
$api = fastly_get_api($form_state['values']['fastly_api_key']);
if (!$api
->validate()) {
form_set_error('', t('Invalid API key.'));
}
fastly_help_message();
}