General: Replace Cheatin’ uh? with friendlier error messages.

While intended as a playful error message, `Cheatin’ uh?` can be interpreted as insulting or accusatory in an already stressful situation. This replaces Cheatin’ with more meaningful error messages, depending on the error that occurs.

Props ElectricFeet, EricMeyer, karmatosed, dd32, BandonRandon, melchoyce for language; dmsnell for original patch; peterwilsoncc.
Fixes #38332.


Built from https://develop.svn.wordpress.org/trunk@42648


git-svn-id: http://core.svn.wordpress.org/trunk@42477 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Peter Wilson
2018-02-05 02:30:34 +00:00
parent a1eb261cd1
commit 0d39b35c11
27 changed files with 50 additions and 49 deletions

View File

@@ -10,7 +10,7 @@
require_once( dirname( __FILE__ ) . '/admin.php' );
if ( ! current_user_can( 'edit_posts' ) ) {
wp_die(
'<h1>' . __( 'Cheatin&#8217; uh?' ) . '</h1>' .
'<h1>' . __( 'You don&#8217;t have permission to do this.' ) . '</h1>' .
'<p>' . __( 'Sorry, you are not allowed to edit comments.' ) . '</p>',
403
);