Merge pull request #10370 from BFTrick/system-status-private

Adding Check in System Status for Private WooCommerce Pages
This commit is contained in:
Mike Jolley 2016-02-19 12:40:49 +00:00
commit 8d391e86e6
1 changed files with 3 additions and 0 deletions

View File

@ -528,6 +528,9 @@ if ( ! defined( 'ABSPATH' ) ) {
if ( ! $page_id ) {
echo '<mark class="error">' . __( 'Page not set', 'woocommerce' ) . '</mark>';
$error = true;
} else if ( get_post_status( $page_id ) !== 'publish' ) {
echo '<mark class="error">' . sprintf( __( 'Page visibility should be %spublic%s', 'woocommerce' ), '<a href="https://codex.wordpress.org/Content_Visibility" target="_blank">', '</a>' ) . '</mark>';
$error = true;
} else {
// Shortcode check