Ticket #34521: pemission-messages-on-wp-includes.patch
File pemission-messages-on-wp-includes.patch, 2.2 KB (added by , 8 years ago) |
---|
-
wp-includes/rest-api/class-wp-rest-server.php
812 812 if ( is_wp_error( $permission ) ) { 813 813 $response = $permission; 814 814 } else if ( false === $permission || null === $permission ) { 815 $response = new WP_Error( 'rest_forbidden', __( "You don't have permission to do this."), array( 'status' => 403 ) );815 $response = new WP_Error( 'rest_forbidden', __( 'You are not allowed to do this.' ), array( 'status' => 403 ) ); 816 816 } 817 817 } 818 818 } -
wp-includes/revision.php
523 523 $id = (int) $_GET['preview_id']; 524 524 525 525 if ( false === wp_verify_nonce( $_GET['preview_nonce'], 'post_preview_' . $id ) ) 526 wp_die( __( 'You do not have permission to preview drafts.') );526 wp_die( __( 'You are not allowed to preview drafts.' ) ); 527 527 528 528 add_filter('the_preview', '_set_preview'); 529 529 } -
wp-includes/script-loader.php
129 129 130 130 $scripts->add( 'wp-ajax-response', "/wp-includes/js/wp-ajax-response$suffix.js", array('jquery'), false, 1 ); 131 131 did_action( 'init' ) && $scripts->localize( 'wp-ajax-response', 'wpAjax', array( 132 'noPerm' => __('You do not have permissionto do that.'),132 'noPerm' => __('You are not allowed to do that.'), 133 133 'broken' => __('An unidentified error has occurred.') 134 134 ) ); 135 135 … … 476 476 if ( is_admin() ) { 477 477 $scripts->add( 'admin-tags', "/wp-admin/js/tags$suffix.js", array( 'jquery', 'wp-ajax-response' ), false, 1 ); 478 478 did_action( 'init' ) && $scripts->localize( 'admin-tags', 'tagsl10n', array( 479 'noPerm' => __('You do not have permissionto do that.'),479 'noPerm' => __('You are not allowed to do that.'), 480 480 'broken' => __('An unidentified error has occurred.') 481 481 )); 482 482