-
Notifications
You must be signed in to change notification settings - Fork 1
Open
Description
Description
Shameless copy/paste from statamic-rad-pack/mailchimp#137
PR: statamic/cms#11403
Before migrating to v5 we could use dynamic audience_id based on our environment using the env:
'audience_id' => env('MAILCHIMP_AUDIENCE_ID'),After upgrading I wanted to accomplish the same using the config, but it breaks everything because the config value isn't being replaced
audience_id: '{{ config:mailchimp:audience_id }}'Taken from API call:
"lists/{{ config:mailchimp:audience_id }}"Steps to reproduce
- Add
audience_idto mailcihmp.php config
'audience_id' => env('MAILCHIMP_AUDIENCE_ID'), - Change
audience_idin newsletter.yaml to use config
audience_id: '{{ config:mailchimp:audience_id }}' - Navigate to
/cp/forms/newsletter/edit - See that you get a fatal error
StatamicRadPack\Mailchimp\Fieldtypes\MailchimpField::callApi(): Return value must be of type ?array, bool returned
Metadata
Metadata
Assignees
Labels
No labels