Skip to main content

Fatal Error with the new trigger AddBadgeAction

Hello,

Any idea here?
When someone registers from a FluentForm submission, Assign a badge Newcomer.

[04-Dec-2024 09:10:38 UTC] PHP Warning: Attempt to read property "meta" on null in /code/wp-content/plugins/fluent-community-pro/app/Services/Integrations/FluentCRM/AddBadgeAction.php on line 112
[04-Dec-2024 09:10:38 UTC] PHP Fatal error: Uncaught Error: Attempt to assign property "meta" on null in /code/wp-content/plugins/fluent-community-pro/app/Services/Integrations/FluentCRM/AddBadgeAction.php:121
Stack trace:
#0 /code/wp-includes/class-wp-hook.php(324): FluentCommunityPro\App\Services\Integrations\FluentCRM\AddBadgeAction->handle(Object(FluentCrm\App\Models\Subscriber), Object(FluentCrm\App\Models\FunnelSequence), 5, Object(FluentCrm\App\Models\FunnelMetric))
#1 /code/wp-includes/class-wp-hook.php(348): WP_Hook->apply_filters('', Array)
#2 /code/wp-includes/plugin.php(517): WP_Hook->do_action(Array)
#3 /code/wp-content/plugins/fluent-crm/app/Services/Funnel/FunnelProcessor.php(216): do_action('fluentcrm_funne...', Object(FluentCrm\App\Models\Subscriber), Object(FluentCrm\App\Models\FunnelSequence), 5, Object(FluentCrm\App\Models\FunnelMetric))
#4 /code/wp-content/plugins/fluent-crm/app/Services/Funnel/FunnelProcessor.php(184): FluentCrm\App\Services\Funnel\FunnelProcessor->processSequence(Object(FluentCrm\App\Models\Subscriber), Object(FluentCrm\App\Models\FunnelSequence), 5)
#5 /code/wp-content/plugins/fluent-crm/app/Services/Funnel/FunnelProcessor.php(119): FluentCrm\App\Services\Funnel\FunnelProcessor->processSequencePoints(Object(FluentCrm\App\Services\Funnel\SequencePoints), Object(FluentCrm\App\Models\Subscriber), Object(FluentCrm\App\Models\FunnelSubscriber))
#6 /code/wp-content/plugins/fluent-crm/app/Services/Funnel/FunnelProcessor.php(89): FluentCrm\App\Services\Funnel\FunnelProcessor->startSequences(Object(FluentCrm\App\Models\Subscriber), Object(FluentCrm\App\Models\Funnel), Array)
#7 /code/wp-content/plugins/fluent-crm/app/Services/Funnel/Triggers/FluentFormSubmissionTrigger.php(246): FluentCrm\App\Services\Funnel\FunnelProcessor->startFunnelSequence(Object(FluentCrm\App\Models\Funnel), Array, Array)
#8 /code/wp-includes/class-wp-hook.php(324): FluentCrm\App\Services\Funnel\Triggers\FluentFormSubmissionTrigger->handle(Object(FluentCrm\App\Models\Funnel), Array)
#9 /code/wp-includes/class-wp-hook.php(348): WP_Hook->apply_filters('', Array)
#10 /code/wp-includes/plugin.php(517): WP_Hook->do_action(Array)
#11 /code/wp-content/plugins/fluent-crm/app/Hooks/Handlers/FunnelHandler.php(108): do_action('fluentcrm_funne...', Object(FluentCrm\App\Models\Funnel), Array)
#12 /code/wp-content/plugins/fluent-crm/app/Hooks/Handlers/FunnelHandler.php(65): FluentCrm\App\Hooks\Handlers\FunnelHandler->mapTriggers('fluentform_subm...', Array, 3)
#13 /code/wp-includes/class-wp-hook.php(324): FluentCrm\App\Hooks\Handlers\FunnelHandler->FluentCrm\App\Hooks\Handlers{closure}(30, Array, Object(FluentForm\App\Models\Form))
#14 /code/wp-includes/class-wp-hook.php(348): WP_Hook->apply_filters('', Array)
#15 /code/wp-includes/plugin.php(517): WP_Hook->do_action(Array)
#16 /code/wp-content/plugins/fluentform/app/Services/Form/SubmissionHandlerService.php(200): do_action('fluentform_subm...', 30, Array, Object(FluentForm\App\Models\Form))
#17 /code/wp-content/plugins/fluentform/app/Services/Form/SubmissionHandlerService.php(51): FluentForm\App\Services\Form\SubmissionHandlerService->processSubmissionData(30, Array, Object(FluentForm\App\Models\Form))
#18 /code/wp-content/plugins/fluentform/app/Modules/SubmissionHandler/SubmissionHandler.php(25): FluentForm\App\Services\Form\SubmissionHandlerService->handleSubmission(Array, 4)
#19 /code/wp-content/plugins/fluentform/app/Hooks/Ajax.php(16): FluentForm\App\Modules\SubmissionHandler\SubmissionHandler->submit()
#20 /code/wp-includes/class-wp-hook.php(324): FluentForm\Framework\Foundation\Application->{closure}('')
#21 /code/wp-includes/class-wp-hook.php(348): WP_Hook->apply_filters('', Array)
#22 /code/wp-includes/plugin.php(517): WP_Hook->do_action(Array)
#23 /code/wp-admin/admin-ajax.php(207): do_action('wp_ajaxnopriv...')
#24 {main}
thrown in /code/wp-content/plugins/fluent-community-pro/app/Services/Integrations/FluentCRM/AddBadgeAction.php on line 121

Shahjahan Jewel

Thanks for reporting. We have fixed the issue already in our dev branch.

Laurent DRAPEAU

Shahjahan JewelΒ Alright. Thx.