Skip to content

Commit

Permalink
Sort crons array by key to ensure timestamps are in the correct order.
Browse files Browse the repository at this point in the history
  • Loading branch information
peterwilsoncc committed Oct 24, 2018
1 parent ced64a3 commit 95f88dd
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions inc/connector/namespace.php
Original file line number Diff line number Diff line change
Expand Up @@ -204,6 +204,8 @@ function get_cron_array( $value ) {
$crons[ $timestamp ][ $hook ][ $key ] = $value;
}

ksort( $crons, SORT_NUMERIC );

// Set the version too
$crons['version'] = 2;

Expand Down

0 comments on commit 95f88dd

Please sign in to comment.