@@ -22,32 +22,32 @@ discard block |
||
22 | 22 | /** |
23 | 23 | * The absolute server path to the fields API directory. |
24 | 24 | */ |
25 | -define( 'WP_FIELDS_API_DIR', plugin_dir_path( __FILE__ ) ); |
|
25 | +define('WP_FIELDS_API_DIR', plugin_dir_path(__FILE__)); |
|
26 | 26 | |
27 | 27 | /** |
28 | 28 | * On `plugins_loaded`, create an instance of the Fields API manager class. |
29 | 29 | */ |
30 | 30 | function _wp_fields_api_include() { |
31 | 31 | |
32 | - require_once( WP_FIELDS_API_DIR . 'implementation/wp-includes/fields-api/class-wp-fields-api.php' ); |
|
32 | + require_once(WP_FIELDS_API_DIR.'implementation/wp-includes/fields-api/class-wp-fields-api.php'); |
|
33 | 33 | |
34 | 34 | // Init Fields API class |
35 | 35 | $GLOBALS['wp_fields'] = WP_Fields_API::get_instance(); |
36 | 36 | |
37 | 37 | } |
38 | 38 | |
39 | -add_action( 'plugins_loaded', '_wp_fields_api_include', 8 ); |
|
39 | +add_action('plugins_loaded', '_wp_fields_api_include', 8); |
|
40 | 40 | |
41 | 41 | /** |
42 | 42 | * Implement Fields API Customizer instead of WP Core Customizer. |
43 | 43 | */ |
44 | 44 | function _wp_fields_api_customize_include() { |
45 | 45 | |
46 | - if ( ! ( ( isset( $_REQUEST['wp_customize'] ) && 'on' == $_REQUEST['wp_customize'] ) || ( is_admin() && 'customize.php' == basename( $_SERVER['PHP_SELF'] ) ) ) ) { |
|
46 | + if ( ! ((isset($_REQUEST['wp_customize']) && 'on' == $_REQUEST['wp_customize']) || (is_admin() && 'customize.php' == basename($_SERVER['PHP_SELF'])))) { |
|
47 | 47 | return; |
48 | 48 | } |
49 | 49 | |
50 | - require_once( WP_FIELDS_API_DIR . 'implementation/wp-includes/class-wp-customize-manager.php' ); |
|
50 | + require_once(WP_FIELDS_API_DIR.'implementation/wp-includes/class-wp-customize-manager.php'); |
|
51 | 51 | |
52 | 52 | // Init Customize class |
53 | 53 | $GLOBALS['wp_customize'] = new WP_Customize_Manager; |
@@ -62,16 +62,16 @@ discard block |
||
62 | 62 | */ |
63 | 63 | function _wp_fields_api_user_edit_include() { |
64 | 64 | |
65 | - require_once( WP_FIELDS_API_DIR . 'implementation/wp-admin/user-edit.php' ); |
|
65 | + require_once(WP_FIELDS_API_DIR.'implementation/wp-admin/user-edit.php'); |
|
66 | 66 | |
67 | 67 | return; |
68 | 68 | |
69 | 69 | // Load our overrides |
70 | - require_once( WP_FIELDS_API_DIR . 'implementation/wp-admin/includes/user.php' ); |
|
71 | - require_once( WP_FIELDS_API_DIR . 'implementation/wp-admin/user-edit.php' ); |
|
70 | + require_once(WP_FIELDS_API_DIR.'implementation/wp-admin/includes/user.php'); |
|
71 | + require_once(WP_FIELDS_API_DIR.'implementation/wp-admin/user-edit.php'); |
|
72 | 72 | |
73 | 73 | // Bail on original core file, don't run the rest |
74 | 74 | exit; |
75 | 75 | |
76 | 76 | } |
77 | -add_action( 'load-user-edit.php', '_wp_fields_api_user_edit_include' ); |
|
78 | 77 | \ No newline at end of file |
78 | +add_action('load-user-edit.php', '_wp_fields_api_user_edit_include'); |
|
79 | 79 | \ No newline at end of file |