Changeset 11940
- Timestamp:
- 07/06/2022 03:44:13 AM (3 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
sites/trunk/wordpress.org/public_html/wp-content/plugins/wporg-o2-posting-access/wporg-o2-allow-crossposting.php
r11587 r11940 27 27 } 28 28 29 // If the current user can't edit posts, they're not going to need this.30 if ( ! current_user_can( 'edit_posts' ) ) {31 return;32 }33 34 29 $this->_current_blog_id = get_current_blog_id(); 35 30 … … 95 90 $data = [ 96 91 'data' => array_values( $xposts->site_suggestions() ), 97 'limit' => 30, // Show all sites92 'limit' => 50, // Show all sites 98 93 ]; 99 94 … … 112 107 */ 113 108 public function user_has_cap( $allcaps, $caps, $args, $user ) { 109 if ( ! is_user_logged_in() ) { 110 return $allcaps; 111 } 112 114 113 if ( $user->ID !== get_current_user_id() ) { 115 114 return $allcaps; … … 189 188 } 190 189 191 $correct = " make.wordpress.org/{$site}/";190 $correct = "{$current_site->domain}/{$site}/"; 192 191 if ( $m[1] !== $correct ) { 193 192 return str_replace( $m[1], $correct, $m[0] );
Note: See TracChangeset
for help on using the changeset viewer.