Changeset 4987 for sites/trunk/wordpress.org/public_html/wp-content/plugins/support-forums/inc/class-hooks.php
- Timestamp:
- 02/22/2017 08:11:40 PM (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
sites/trunk/wordpress.org/public_html/wp-content/plugins/support-forums/inc/class-hooks.php
r4974 r4987 40 40 add_action( 'bbp_new_reply', array( $this, 'handle_extra_reply_actions' ), 10, 2 ); 41 41 add_action( 'bbp_edit_reply', array( $this, 'handle_extra_reply_actions' ), 10, 2 ); 42 43 // Store moderator's username on approve/unapprove actions. 44 add_action( 'bbp_approved_topic', array( $this, 'store_moderator_username' ) ); 45 add_action( 'bbp_approved_reply', array( $this, 'store_moderator_username' ) ); 46 add_action( 'bbp_unapproved_topic', array( $this, 'store_moderator_username' ) ); 47 add_action( 'bbp_unapproved_reply', array( $this, 'store_moderator_username' ) ); 42 48 } 43 49 … … 267 273 } 268 274 275 /** 276 * Store moderator's username on approve/unapprove actions. 277 * 278 * @param int $post_id Post ID. 279 */ 280 public function store_moderator_username( $post_id ) { 281 update_post_meta( $post_id, '_wporg_bbp_moderator', wp_get_current_user()->user_login ); 282 } 283 269 284 }
Note: See TracChangeset
for help on using the changeset viewer.