humanmade / Cavalcade

A better wp-cron. Horizontally scalable, works perfectly with multisite.
https://engineering.hmn.md/projects/cavalcade/
Other
512 stars 46 forks source link

Incorrect pre_get_ready_cron_jobs implementation #103

Closed dd32 closed 3 years ago

dd32 commented 3 years ago

This fixes a fatal error when something requests wp-cron.php while Cavalcade is in use:

Uncaught Error: Cannot use object of type stdClass as array in /public_html/wp-cron.php:121

It seems that Cavalcade returns an object here, where WordPress is expecting an array: https://core.trac.wordpress.org/browser/trunk/src/wp-cron.php?marks=121#L112

roborourke commented 3 years ago

I think there were places in the cavalcade code that expected an object, iirc it was to do with converting it into a Job object but given the tests pass it must've been a hangover from v1.

roborourke commented 3 years ago

Released in 2.0.1