Making WordPress.org

Changeset 9662


Ignore:
Timestamp:
03/31/2020 10:07:33 PM (4 years ago)
Author:
ryelle
Message:

Official WordPress Events: Sync the start time of WordCamps using the session start time value

This value is pulled from the first running session, which is a more realistic time for when a WordCamp starts. This is useful for online events, identifying what time someone should join in. If this value is not set, fall back to the Start Date in the WordCamp meta.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sites/trunk/wordpress.org/public_html/wp-content/plugins/official-wordpress-events/official-wordpress-events.php

    r9661 r9662  
    335335                                continue 3;
    336336                            }
    337                             $event['start_timestamp'] = $value;
     337                            if ( ! $wordcamp->session_start_time ) {
     338                                $event['start_timestamp'] = $value;
     339                            } else {
     340                                $event['start_timestamp'] = absint( $wordcamp->session_start_time );
     341                            }
    338342                            break;
    339343
    340344                        case 'End Date (YYYY-mm-dd)':
    341                             $value                  = absint( $value );
    342                             $event['end_timestamp'] = $value;
     345                            $event['end_timestamp'] = absint( $value );
    343346                            break;
    344347
Note: See TracChangeset for help on using the changeset viewer.