Get The Most Affordable Hosting in the World!

Starting at just $1.87/month, Vercaa offers unbeatable pricing for world-class web hosting services.

Fast, reliable, and secure hosting to power your website without breaking the bank. Plus, enjoy a free CDN for faster loading times worldwide!

Get Started Now!

Symptom

After updating to WHMCS 8.6.1, you may see a TypeError error when sending Email Marketer rules during the automation tasks:

TypeError: array_search(): Argument #2 ($haystack) must be of type 
array, null given in 
/path/to/whmcs/vendor/whmcs/whmcs-foundation/lib/Cron/Task/EmailMarketer.php:0
 

Cause

An invalid value in the Email Marketer rule (missing billing cycle) causes an error in PHP 8.1 environments only.

Workaround

To work around this issue:

  1. Go to Utilities > Email Marketer .
  2. Edit the first Email Marketer rule.
  3. Without making any changes, click Save Changes.
  4. Repeat this process for each Email Marketer rule.

After you do this for all of your Email Marketer rules, the error will resolve.

 

 

The End! should you have any inquiries, we encourage you to reach out to the Vercaa Support Center without hesitation.

Was this answer helpful? 1 Users Found This Useful (1 Votes)