Add default value to `db_datetime_format` for back compatibility

Co-authored-by: Chi-Hsuan Huang <chihsuan.tw@gmail.com>
This commit is contained in:
Christos Lilitsas 2022-05-25 16:26:20 +03:00 committed by GitHub
parent 7ed7ad2fde
commit d057225e07
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -82,7 +82,7 @@ class TimeInterval {
* @param string $date_column_name Name of the date table column.
* @return mixed
*/
public static function db_datetime_format( $time_interval, $table_name, $date_column_name ) {
public static function db_datetime_format( $time_interval, $table_name, $date_column_name = 'date_created' ) {
$first_day_of_week = absint( get_option( 'start_of_week' ) );
if ( 1 === $first_day_of_week ) {