Ticket #13917: 13917-refresh.2.diff
| File 13917-refresh.2.diff, 685 bytes (added by maxcutler, 8 months ago) |
|---|
-
wp-includes/class-wp-xmlrpc-server.php
4894 4894 return new IXR_Error(500, $errorString); 4895 4895 } 4896 4896 // Construct the attachment array 4897 // attach to post_id 04898 4897 $post_id = 0; 4898 if ( ! empty( $data['post_id'] ) ) { 4899 $post_id = (int) $data['post_id']; 4900 4901 if ( ! current_user_can( 'edit_post', $post_id ) ) 4902 return new IXR_Error( 401, __( 'Sorry, you cannot edit this post.' ) ); 4903 } 4899 4904 $attachment = array( 4900 4905 'post_title' => $name, 4901 4906 'post_content' => '',
