This commit is contained in:
Mike Jolley 2019-01-23 16:19:40 +00:00
parent 9cdcc3f1e5
commit a2f77ba7ec
1 changed files with 3 additions and 7 deletions

View File

@ -12,9 +12,7 @@
* @package WooCommerce
*/
if ( ! defined( 'ABSPATH' ) ) {
exit; // Exit if accessed directly.
}
defined( 'ABSPATH' ) || exit;
// Define WC_PLUGIN_FILE.
if ( ! defined( 'WC_PLUGIN_FILE' ) ) {
@ -27,14 +25,12 @@ if ( ! class_exists( 'WooCommerce' ) ) {
}
/**
* Main instance of WooCommerce.
*
* Returns the main instance of WC to prevent the need to use globals.
* Returns the main instance of WC.
*
* @since 2.1
* @return WooCommerce
*/
function WC() {
function WC() { // phpcs:ignore
return WooCommerce::instance();
}