Skip to:
Content

bbPress.org


Ignore:
Timestamp:
03/02/2017 04:46:00 AM (9 years ago)
Author:
johnjamesjacoby
Message:

Moderation: Use the appropriate _edit_ post meta when editing a forum/topic/reply.

This first pass does not introduce any theme-side edit-locking interface, but it will warn any user within wp-admin if another user is editing something theme-side.

See #3073.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/includes/core/theme-compat.php

    r6314 r6341  
    578578        ) );
    579579
     580        // Lock the forum from other edits
     581        bbp_set_post_lock( bbp_get_forum_id() );
     582
    580583    } elseif ( bbp_is_single_forum() ) {
    581584
     
    644647
    645648        // Edit
    646         } elseif ( bbp_is_topic_edit() ) {
     649        } elseif ( bbp_is_topic_edit() ) {         
    647650            $new_content = $bbp_shortcodes->display_topic_form();
     651
     652            // Lock the topic from other edits
     653            bbp_set_post_lock( bbp_get_topic_id() );
    648654
    649655        // Single
     
    694700            $new_content = $bbp_shortcodes->display_reply_form();
    695701
     702            // Lock the topic from other edits
     703            bbp_set_post_lock( bbp_get_reply_id() );
     704
    696705        // Single
    697706        } else {
Note: See TracChangeset for help on using the changeset viewer.