Replace 7 * DAY_IN_SECONDS
with WEEK_IN_SECONDS
in get_weekstartend()
.
Props MikeHansenMe. Fixes #34603. git-svn-id: https://develop.svn.wordpress.org/trunk@35556 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
207ab0db7d
commit
7d039b4e40
@ -301,8 +301,8 @@ function get_weekstartend( $mysqlstring, $start_of_week = '' ) {
|
||||
// The most recent week start day on or before $day.
|
||||
$start = $day - DAY_IN_SECONDS * ( $weekday - $start_of_week );
|
||||
|
||||
// $start + 7 days - 1 second.
|
||||
$end = $start + 7 * DAY_IN_SECONDS - 1;
|
||||
// $start + 1 week - 1 second.
|
||||
$end = $start + WEEK_IN_SECONDS - 1;
|
||||
return compact( 'start', 'end' );
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user