Skip to content

fix undefined constant error on large syncs

JonGold requested to merge JonGold/mailchimpsync:done-constant into master

CRM_Mailchimpsync_Audience::reconcileQueueProcess() contains this line:

'andLog' => "reconcileQueueProcess: Reconciled $stats[done], " . ($stats['count'] - $stats[done]) . " remaining but ran out of time. So far, $mailchimp_updates updates to Mailchimp in the queue.",

This line causes an undefined constant 'done' error when triggered.

While $stats[done] is legitimate within a string, it's not legitimate outside a string, as in the second instance. For consistency, I've rewritten the whole line to use $stats['done'] in both places.

Merge request reports

Loading