Skip to content

Commit e732e3e

Browse files
committed
corrected date calculation of "today".
1 parent 8c48ef0 commit e732e3e

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

public/class-wplibcalhours-public.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -269,7 +269,8 @@ protected function extract_hours( array $weeks_raw_data ) {
269269
*/
270270
public function api() {
271271
$ignore_cache = (boolean) get_option( 'wplibcalhours_ignore_cache' );
272-
$now = date( 'Y-m-d' );
272+
$timestamp = current_time( 'timestamp' );
273+
$now = date('Y-m-d', $timestamp);
273274
try {
274275
$data = $this->client->getRawData( $ignore_cache );
275276
$rhett = [];

0 commit comments

Comments
 (0)