Record $record
* @param string $type
*
* @return array
*/
private function get_file_by_attachment_type( $form_fields, $record, $type ) {
return Collection::make( $form_fields )
->filter( function ( $field ) use ( $type ) {
return $type === $field['attachment_type'];
} )
->map( function ( $field ) use ( $record ) {
$id = $field['custom_id'];
return $record->get( 'files' )[ $id ]['path'] ?? null;
} )
->filter()
->flatten()
->values();
}
}
Fatal error: Uncaught Error: Class 'ElementorPro\Modules\Forms\Actions\Email' not found in /home/sportuga/public_html/wp-content/plugins/elementor-pro/modules/forms/registrars/form-actions-registrar.php:57
Stack trace:
#0 /home/sportuga/public_html/wp-includes/class-wp-hook.php(324): ElementorPro\Modules\Forms\Registrars\Form_Actions_Registrar->ElementorPro\Modules\Forms\Registrars\{closure}(Object(ElementorPro\Modules\Forms\Registrars\Form_Actions_Registrar))
#1 /home/sportuga/public_html/wp-includes/class-wp-hook.php(348): WP_Hook->apply_filters(NULL, Array)
#2 /home/sportuga/public_html/wp-includes/plugin.php(517): WP_Hook->do_action(Array)
#3 /home/sportuga/public_html/wp-content/plugins/elementor-pro/modules/forms/registrars/form-actions-registrar.php(84): do_action('elementor_pro/f...', Object(ElementorPro\Modules\Forms\Registrars\Form_Actions_Registrar))
#4 /home/sportuga/public_html/wp-content/plugins/elementor-pro/modules/forms/registrars/form-actions-registrar.php(42): ElementorPro\Modules\Forms\Registrars\Form_ in /home/sportuga/public_html/wp-content/plugins/elementor-pro/modules/forms/registrars/form-actions-registrar.php on line 57