Skip to:
Content

bbPress.org


Ignore:
Timestamp:
02/10/2011 08:33:59 AM (16 years ago)
Author:
johnjamesjacoby
Message:

Add ability for capable users to edit anonymous topic/post user data. Fixes #1463.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/bb-includes/functions.bb-posts.php

    r2821 r2860  
    402402                $post_id = $topic_last_post_id = (int) $bbdb->insert_id;
    403403
    404                 // if user not logged in, save user data as meta data
    405                 if ( !$user ) {
    406                         bb_update_meta($post_id, 'post_author', $post_author, 'post');
    407                         bb_update_meta($post_id, 'post_email', $post_email, 'post');
    408                         bb_update_meta($post_id, 'post_url', $post_url, 'post');
    409                 }
    410 
    411404                if ( 0 == $post_status ) {
    412405                        $topic_time = $post_time;
     
    432425        }
    433426        bb_update_topic_voices( $topic_id );
     427
     428        // if user not logged in, save user data as meta data
     429        if ( !$user ) {
     430                bb_update_meta($post_id, 'post_author', $post_author, 'post');
     431                bb_update_meta($post_id, 'post_email', $post_email, 'post');
     432                bb_update_meta($post_id, 'post_url', $post_url, 'post');
     433        }
    434434       
    435435        if ( $throttle && !bb_current_user_can( 'throttle' ) ) {
Note: See TracChangeset for help on using the changeset viewer.