From b2aaeb8394e4b88e5b8788626650065d9dc8747f Mon Sep 17 00:00:00 2001 From: Dion Hulse Date: Thu, 1 Apr 2010 10:30:58 +0000 Subject: [PATCH] Small coding standards cleanup of wp_die(); git-svn-id: https://develop.svn.wordpress.org/trunk@13910 602fd350-edb4-49c9-b593-d223f7449a82 --- wp-includes/functions.php | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/wp-includes/functions.php b/wp-includes/functions.php index 9dee68fc79..0842371b16 100644 --- a/wp-includes/functions.php +++ b/wp-includes/functions.php @@ -2641,19 +2641,20 @@ function _default_wp_die_handler( $message, $title = '', $args = array() ) { $admin_dir = 'wp-admin/'; if ( !function_exists( 'did_action' ) || !did_action( 'admin_head' ) ) : - if ( !headers_sent() ){ + if ( !headers_sent() ) { status_header( $r['response'] ); nocache_headers(); header( 'Content-Type: text/html; charset=utf-8' ); } - if ( empty($title) ) { - $title = $have_gettext? __('WordPress › Error') : 'WordPress › Error'; - } + if ( empty($title) ) + $title = $have_gettext ? __('WordPress › Error') : 'WordPress › Error'; $text_direction = 'ltr'; - if ( isset($r['text_direction']) && $r['text_direction'] == 'rtl' ) $text_direction = 'rtl'; - if ( ( $wp_locale ) && ( 'rtl' == $wp_locale->text_direction ) ) $text_direction = 'rtl'; + if ( isset($r['text_direction']) && 'rtl' == $r['text_direction'] ) + $text_direction = 'rtl'; + elseif ( isset($wp_locale ) && 'rtl' == $wp_locale->text_direction ) + $text_direction = 'rtl'; ?>