function flag_form_submit in Flag 8.4
Same name and namespace in other branches
- 5 includes/flag.admin.inc \flag_form_submit()
- 6.2 includes/flag.admin.inc \flag_form_submit()
- 6 includes/flag.admin.inc \flag_form_submit()
- 7.3 includes/flag.admin.inc \flag_form_submit()
- 7.2 includes/flag.admin.inc \flag_form_submit()
Form submission handler for the flag module.
See also
1 string reference to 'flag_form_submit'
- flag_form_alter in ./
flag.module - Implements hook_form_alter().
File
- ./
flag.module, line 196 - The Flag module.
Code
function flag_form_submit($form, FormStateInterface $form_state) {
$entity = $form_state
->getFormObject()
->getEntity();
if (!$form_state
->isValueEmpty('flag')) {
$values = $form_state
->getValue('flag');
flag_form_save($entity, $values);
}
}