Making WordPress.org

Changeset 2800


Ignore:
Timestamp:
03/25/2016 09:51:08 AM (10 years ago)
Author:
kovshenin
Message:

WordCamp Post Type: Use time() for timestamps.

The current_time() function depends on blog settings,
while time() is always UTC, which can then be easily
converted to any other timezone offset regardless
of any blog settings now or in the future.

Location:
sites/branches/application-tracking/wordcamp.org/public_html/wp-content/plugins/wcpt
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • sites/branches/application-tracking/wordcamp.org/public_html/wp-content/plugins/wcpt/applications/wordcamp.php

    r2797 r2800  
    195195
    196196    add_post_meta( $post_id, '_status_change', array(
    197         'timestamp' => current_time( 'timestamp' ),
     197        'timestamp' => time(),
    198198        'user_id'   => $user->ID,
    199199        'message'   => sprintf( '%s -> %s', 'Application', 'Draft' ), /// todo use get_status_name() when it's ready    // todo update with new default status
  • sites/branches/application-tracking/wordcamp.org/public_html/wp-content/plugins/wcpt/wcpt-wordcamp/wordcamp-admin.php

    r2784 r2800  
    213213
    214214        add_post_meta( $post_id, '_note', array(
    215             'timestamp' => current_time( 'timestamp' ),
     215            'timestamp' => time(),
    216216            'user_id'   => get_current_user_id(),
    217217            'message'   => $new_note_message,
     
    624624
    625625        add_post_meta( $post->ID, '_status_change', array(
    626             'timestamp' => current_time( 'timestamp' ),
     626            'timestamp' => time(),
    627627            'user_id'   => get_current_user_id(),
    628628            'message'   => sprintf( '%s -> %s', $old_status, $new_status ), /// todo use get_status_name() when it's ready
Note: See TracChangeset for help on using the changeset viewer.