function flickr_user_account_form_validate in Flickr 7
Validates a user's Flickr account calling flickr_user_find_by_identifier().
1 string reference to 'flickr_user_account_form_validate'
- flickr_form_user_profile_form_alter in ./
flickr.module - Implements hook_form_user_profile_form_alter(). Adds the Flickr form to the user profile form.
File
- ./
flickr.module, line 336 - The Flickr module.
Code
function flickr_user_account_form_validate(&$form, &$form_state) {
if (!empty($form_state['values']['flickr_identifier'])) {
if (!flickr_user_find_by_identifier($form_state['values']['flickr_identifier'])) {
form_set_error('flickr_identifier', t('%ident is not a valid Flickr username, email, or NSID.', array(
'%ident' => $form_state['values']['flickr_identifier'],
)));
}
}
}