@@ -315,7 +315,7 @@ function wp_schedule_event( $timestamp, $recurrence, $hook, $args = array(), $wp
315315/**
316316 * Reschedules a recurring event.
317317 *
318- * Mainly for internal use, this takes the UTC timestamp of a previously run
318+ * Mainly for internal use, this takes the Unix timestamp (UTC) of a previously run
319319 * recurring event and reschedules it for its next run.
320320 *
321321 * To change upcoming scheduled events, use wp_schedule_event() to
@@ -485,7 +485,7 @@ function wp_unschedule_event( $timestamp, $hook, $args = array(), $wp_error = fa
485485 * @since 5.7.0 The `$wp_error` parameter was added, and a `WP_Error` object can now be returned.
486486 *
487487 * @param null|bool|WP_Error $pre Value to return instead. Default null to continue unscheduling the event.
488- * @param int $timestamp Timestamp for when to run the event.
488+ * @param int $timestamp Unix timestamp (UTC) for when to run the event.
489489 * @param string $hook Action hook, the execution of which will be unscheduled.
490490 * @param array $args Arguments to pass to the hook's callback function.
491491 * @param bool $wp_error Whether to return a WP_Error on failure.
@@ -818,7 +818,7 @@ function wp_get_scheduled_event( $hook, $args = array(), $timestamp = null ) {
818818}
819819
820820/**
821- * Retrieves the next timestamp for an event .
821+ * Retrieves the timestamp of the next scheduled event for the given hook .
822822 *
823823 * @since 2.1.0
824824 *
@@ -827,7 +827,7 @@ function wp_get_scheduled_event( $hook, $args = array(), $timestamp = null ) {
827827 * Although not passed to a callback, these arguments are used to uniquely identify the
828828 * event, so they should be the same as those used when originally scheduling the event.
829829 * Default empty array.
830- * @return int|false The Unix timestamp of the next time the event will occur. False if the event doesn't exist.
830+ * @return int|false The Unix timestamp (UTC) of the next time the event will occur. False if the event doesn't exist.
831831 */
832832function wp_next_scheduled ( $ hook , $ args = array () ) {
833833 $ next_event = wp_get_scheduled_event ( $ hook , $ args );
@@ -836,7 +836,27 @@ function wp_next_scheduled( $hook, $args = array() ) {
836836 return false ;
837837 }
838838
839- return $ next_event ->timestamp ;
839+ /**
840+ * Filters the timestamp of the next scheduled event for the given hook.
841+ *
842+ * @since 6.8.0
843+ *
844+ * @param int $timestamp Unix timestamp (UTC) for when to next run the event.
845+ * @param object $next_event {
846+ * An object containing an event's data.
847+ *
848+ * @type string $hook Action hook of the event.
849+ * @type int $timestamp Unix timestamp (UTC) for when to next run the event.
850+ * @type string $schedule How often the event should subsequently recur.
851+ * @type array $args Array containing each separate argument to pass to the hook
852+ * callback function.
853+ * @type int $interval Optional. The interval time in seconds for the schedule. Only
854+ * present for recurring events.
855+ * }
856+ * @param array $args Array containing each separate argument to pass to the hook
857+ * callback function.
858+ */
859+ return apply_filters ( 'wp_next_scheduled ' , $ next_event ->timestamp , $ next_event , $ hook , $ args );
840860}
841861
842862/**
@@ -929,7 +949,7 @@ function spawn_cron( $gmt_time = 0 ) {
929949 * @type bool $sslverify Whether SSL should be verified for the request. Default false.
930950 * }
931951 * }
932- * @param string $doing_wp_cron The unix timestamp of the cron lock.
952+ * @param string $doing_wp_cron The Unix timestamp (UTC) of the cron lock.
933953 */
934954 $ cron_request = apply_filters (
935955 'cron_request ' ,
0 commit comments