[wp-trac] [WordPress Trac] #40161: Wrong documented or coded 'schedule_event' filter
WordPress Trac
noreply at wordpress.org
Sat Mar 18 08:36:33 UTC 2017
#40161: Wrong documented or coded 'schedule_event' filter
-----------------------------------------+------------------------------
Reporter: esemlabel | Owner:
Type: enhancement | Status: new
Priority: normal | Milestone: Awaiting Review
Component: Cron API | Version:
Severity: normal | Resolution:
Keywords: has-patch reporter-feedback | Focuses:
-----------------------------------------+------------------------------
Comment (by esemlabel):
Yes, someone can return false to short-circuit this. But many of other
developers will produce error when hook in to their even with filter
{{{
if ( $event->hook === 'my_plugin_event' ) then perform something inside my
plugin
}}}
, because they can't predict if anyone else will use such way to prevent
event from running.
The one way without modifying core is always use low priority for every
filter hook, that return false to 'schedule_event' filter. Otherwise,
there is huge probability to catch debug error from plugins and themes.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/40161#comment:4>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list