diff --git src/wp-admin/includes/class-wp-community-events.php src/wp-admin/includes/class-wp-community-events.php
index 2237ab34e4..98325a82c5 100644
|
|
class WP_Community_Events { |
378 | 378 | /* translators: Date format for upcoming events on the dashboard. Include the day of the week. See https://secure.php.net/date. */ |
379 | 379 | $response_body['events'][ $key ]['formatted_date'] = date_i18n( __( 'l, M j, Y' ), $timestamp ); |
380 | 380 | $response_body['events'][ $key ]['formatted_time'] = date_i18n( get_option( 'time_format' ), $timestamp ); |
| 381 | |
| 382 | if ( isset( $event['end_date'] ) ) { |
| 383 | $end_timestamp = strtotime( $event['end_date'] ); |
| 384 | $formatted_end_date = date_i18n( __( 'l, M j, Y' ), $end_timestamp ); |
| 385 | |
| 386 | if ( 'meetup' !== $response_body['events'][ $key ]['type'] && $response_body['events'][ $key ]['formatted_date'] !== $formatted_end_date ) { |
| 387 | /* Translators: %1$s is for the month, %2$d is for the starting day, %2$d is for the ending day, %4$d is for the year */ |
| 388 | $response_body['events'][ $key ]['formatted_date'] = sprintf( |
| 389 | __( '%1$s %2$d-%3$d, %4$d' ), |
| 390 | date_i18n( __( 'F' ), $timestamp ), |
| 391 | date_i18n( __( 'j' ), $timestamp ), |
| 392 | date_i18n( __( 'j' ), $end_timestamp ), |
| 393 | date_i18n( __( 'Y' ), $timestamp ) |
| 394 | ); |
| 395 | } |
| 396 | } |
381 | 397 | } |
382 | 398 | } |
383 | 399 | |