function commerce_kickstart_form_install_configure_submit in Commerce Kickstart 3.x
Submission handler to sync the contact.form.feedback recipient.
1 string reference to 'commerce_kickstart_form_install_configure_submit'
- commerce_kickstart_form_install_configure_form_alter in ./
commerce_kickstart.profile - Implements hook_form_FORM_ID_alter() for install_configure_form().
File
- ./
commerce_kickstart.profile, line 25 - Enables modules and site configuration for a commerce_base site installation.
Code
function commerce_kickstart_form_install_configure_submit($form, FormStateInterface $form_state) {
$site_mail = $form_state
->getValue('site_mail');
ContactForm::load('feedback')
->setRecipients([
$site_mail,
])
->trustData()
->save();
}