Changeset 5829 for trunk/src/includes/admin/forums.php
- Timestamp:
- 07/14/2015 12:46:38 AM (11 years ago)
- File:
-
- 1 edited
-
trunk/src/includes/admin/forums.php (modified) (6 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/includes/admin/forums.php
r5770 r5829 92 92 */ 93 93 private function bail() { 94 if ( ! isset( get_current_screen()->post_type ) || ( $this->post_type != get_current_screen()->post_type ) ) {94 if ( ! isset( get_current_screen()->post_type ) || ( $this->post_type != get_current_screen()->post_type ) ) { 95 95 return true; 96 96 } … … 301 301 302 302 // Nonce check 303 if ( empty( $_POST['bbp_forum_metabox'] ) || ! wp_verify_nonce( $_POST['bbp_forum_metabox'], 'bbp_forum_metabox_save' ) ) {303 if ( empty( $_POST['bbp_forum_metabox'] ) || ! wp_verify_nonce( $_POST['bbp_forum_metabox'], 'bbp_forum_metabox_save' ) ) { 304 304 return $forum_id; 305 305 } … … 316 316 317 317 // Parent ID 318 $parent_id = ( ! empty( $_POST['parent_id'] ) && is_numeric( $_POST['parent_id'] ) ) ? (int) $_POST['parent_id'] : 0;318 $parent_id = ( ! empty( $_POST['parent_id'] ) && is_numeric( $_POST['parent_id'] ) ) ? (int) $_POST['parent_id'] : 0; 319 319 320 320 // Update the forum meta bidness … … 437 437 438 438 // Only proceed if GET is a forum toggle action 439 if ( bbp_is_get_request() && ! empty( $_GET['action'] ) && in_array( $_GET['action'], array( 'bbp_toggle_forum_close' ) ) && !empty( $_GET['forum_id'] ) ) {439 if ( bbp_is_get_request() && ! empty( $_GET['action'] ) && in_array( $_GET['action'], array( 'bbp_toggle_forum_close' ) ) && ! empty( $_GET['forum_id'] ) ) { 440 440 $action = $_GET['action']; // What action is taking place? 441 441 $forum_id = (int) $_GET['forum_id']; // What's the forum id? … … 505 505 506 506 // Only proceed if GET is a forum toggle action 507 if ( bbp_is_get_request() && ! empty( $_GET['bbp_forum_toggle_notice'] ) && in_array( $_GET['bbp_forum_toggle_notice'], array( 'opened', 'closed' ) ) && !empty( $_GET['forum_id'] ) ) {507 if ( bbp_is_get_request() && ! empty( $_GET['bbp_forum_toggle_notice'] ) && in_array( $_GET['bbp_forum_toggle_notice'], array( 'opened', 'closed' ) ) && ! empty( $_GET['forum_id'] ) ) { 508 508 $notice = $_GET['bbp_forum_toggle_notice']; // Which notice? 509 509 $forum_id = (int) $_GET['forum_id']; // What's the forum id? 510 $is_failure = ! empty( $_GET['failed'] ) ? true : false; // Was that a failure?510 $is_failure = ! empty( $_GET['failed'] ) ? true : false; // Was that a failure? 511 511 512 512 // Bail if no forum_id or notice … … 621 621 case 'bbp_forum_freshness' : 622 622 $last_active = bbp_get_forum_last_active_time( $forum_id, false ); 623 if ( ! empty( $last_active ) ) {623 if ( ! empty( $last_active ) ) { 624 624 echo esc_html( $last_active ); 625 625 } else {
Note: See TracChangeset
for help on using the changeset viewer.