Skip to:
Content

BuddyPress.org

Changeset 8185


Ignore:
Timestamp:
03/28/2014 12:35:11 AM (10 years ago)
Author:
johnjamesjacoby
Message:

Revert r8183; broke unit tests as these functions can be called after headers are sent (which needs further investigation in a separate ticket.)

Location:
trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/bp-core/bp-core-functions.php

    r8183 r8185  
    927927
    928928    // Send the values to the cookie for page reload display
    929     setcookie( 'bp-message',      $message, time() + 60 * 60 * 24, COOKIEPATH );
    930     setcookie( 'bp-message-type', $type,    time() + 60 * 60 * 24, COOKIEPATH );
     929    @setcookie( 'bp-message',      $message, time() + 60 * 60 * 24, COOKIEPATH );
     930    @setcookie( 'bp-message-type', $type,    time() + 60 * 60 * 24, COOKIEPATH );
    931931
    932932    // Get BuddyPress
     
    969969
    970970    if ( isset( $_COOKIE['bp-message'] ) ) {
    971         setcookie( 'bp-message', false, time() - 1000, COOKIEPATH );
     971        @setcookie( 'bp-message', false, time() - 1000, COOKIEPATH );
    972972    }
    973973
    974974    if ( isset( $_COOKIE['bp-message-type'] ) ) {
    975         setcookie( 'bp-message-type', false, time() - 1000, COOKIEPATH );
     975        @setcookie( 'bp-message-type', false, time() - 1000, COOKIEPATH );
    976976    }
    977977}
  • trunk/bp-messages/bp-messages-functions.php

    r8183 r8185  
    186186
    187187function messages_add_callback_values( $recipients, $subject, $content ) {
    188     setcookie( 'bp_messages_send_to', $recipients, time() + 60 * 60 * 24, COOKIEPATH );
    189     setcookie( 'bp_messages_subject', $subject,    time() + 60 * 60 * 24, COOKIEPATH );
    190     setcookie( 'bp_messages_content', $content,    time() + 60 * 60 * 24, COOKIEPATH );
     188    @setcookie( 'bp_messages_send_to', $recipients, time() + 60 * 60 * 24, COOKIEPATH );
     189    @setcookie( 'bp_messages_subject', $subject,    time() + 60 * 60 * 24, COOKIEPATH );
     190    @setcookie( 'bp_messages_content', $content,    time() + 60 * 60 * 24, COOKIEPATH );
    191191}
    192192
    193193function messages_remove_callback_values() {
    194     setcookie( 'bp_messages_send_to', false, time() - 1000, COOKIEPATH );
    195     setcookie( 'bp_messages_subject', false, time() - 1000, COOKIEPATH );
    196     setcookie( 'bp_messages_content', false, time() - 1000, COOKIEPATH );
     194    @setcookie( 'bp_messages_send_to', false, time() - 1000, COOKIEPATH );
     195    @setcookie( 'bp_messages_subject', false, time() - 1000, COOKIEPATH );
     196    @setcookie( 'bp_messages_content', false, time() - 1000, COOKIEPATH );
    197197}
    198198
Note: See TracChangeset for help on using the changeset viewer.