Ticket #2787: 2787.patch
| File 2787.patch, 1.5 KB (added by , 9 years ago) |
|---|
-
sites/trunk/wordpress.org/public_html/wp-content/plugins/plugin-directory/shortcodes/class-upload-handler.php
96 96 97 97 $plugin_post = Plugin_Directory::get_plugin_post( $this->plugin_slug ); 98 98 99 // Is there already a plugin by a different author?99 // Is there already a plugin with the same slug by a different author? 100 100 if ( $plugin_post && $plugin_post->post_author != get_current_user_id() ) { 101 101 /* translators: 1: plugin slug, 2: 'Plugin Name:' */ 102 102 return sprintf( __( 'There is already a plugin called %1$s by a different author. Please change the %2$s line in your main plugin file and upload it again.', 'wporg-plugins' ), … … 105 105 ); 106 106 } 107 107 108 // Check the plugin can accept uploads (New submissions, or pending further review).109 if ( $plugin_post && ! in_array( $plugin_post->post_status, array( 'new', 'pending' ) )) {108 // Is there already a plugin with the same slug by the same author? 109 if ( $plugin_post ) { 110 110 /* translators: 1: plugin slug, 2: 'Plugin Name:' */ 111 111 return sprintf( __( 'There is already a plugin called %1$s. Please change the %2$s line in your main plugin file and upload it again.', 'wporg-plugins' ), 112 112 '<code>' . $this->plugin_slug . '</code>',