Changeset 12281 for trunk/src/bp-blogs/bp-blogs-activity.php
- Timestamp:
- 11/07/2018 04:09:00 PM (7 years ago)
- File:
-
- 1 edited
-
trunk/src/bp-blogs/bp-blogs-activity.php (modified) (4 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/bp-blogs/bp-blogs-activity.php
r12169 r12281 1159 1159 // Initialize a local object so we won't have to query this again in the 1160 1160 // comment loop. 1161 if ( empty( buddypress()->blogs->allow_comments ) ) {1161 if ( ! isset( buddypress()->blogs->allow_comments ) ) { 1162 1162 buddypress()->blogs->allow_comments = array(); 1163 1163 } 1164 if ( empty( buddypress()->blogs->thread_depth ) ) {1164 if ( ! isset( buddypress()->blogs->thread_depth ) ) { 1165 1165 buddypress()->blogs->thread_depth = array(); 1166 1166 } 1167 if ( empty( buddypress()->blogs->comment_moderation ) ) {1167 if ( ! isset( buddypress()->blogs->comment_moderation ) ) { 1168 1168 buddypress()->blogs->comment_moderation = array(); 1169 1169 } … … 1243 1243 // If comments are closed for the WP blog post, we should disable 1244 1244 // activity comments for this activity entry. 1245 if ( empty( buddypress()->blogs->allow_comments[ bp_get_activity_id() ] )) {1245 if ( ! isset( buddypress()->blogs->allow_comments[ bp_get_activity_id() ] ) || ! buddypress()->blogs->allow_comments[ bp_get_activity_id() ] ) { 1246 1246 $retval = false; 1247 1247 } 1248 1248 1249 1249 // If comments need moderation, disable activity commenting. 1250 if ( ! empty( buddypress()->blogs->comment_moderation[ bp_get_activity_id() ] )) {1250 if ( isset( buddypress()->blogs->comment_moderation[ bp_get_activity_id() ] ) && buddypress()->blogs->comment_moderation[ bp_get_activity_id() ] ) { 1251 1251 $retval = false; 1252 1252 } … … 1329 1329 // The blog post has closed off commenting, so we should disable all activity 1330 1330 // comments under the parent 'new_blog_post' activity entry. 1331 if ( empty( buddypress()->blogs->allow_comments[$comment->item_id] )) {1331 if ( ! buddypress()->blogs->allow_comments[ $comment->item_id ] ) { 1332 1332 $retval = false; 1333 1333 } … … 1335 1335 1336 1336 // If comments need moderation, disable activity commenting. 1337 if ( ! empty( buddypress()->blogs->comment_moderation[$comment->item_id] )) {1337 if ( isset( buddypress()->blogs->comment_moderation[ $comment->item_id ] ) && buddypress()->blogs->comment_moderation[ $comment->item_id ] ) { 1338 1338 $retval = false; 1339 1339 }
Note: See TracChangeset
for help on using the changeset viewer.