Function save_ldp_meta_for_post
has a Cognitive Complexity of 78 (exceeds 5 allowed). Consider refactoring. Open
public function save_ldp_meta_for_post( $resource_id ) {
$fields = Utils::get_resource_fields_list( $resource_id );
if ( ! empty( $fields ) ) {
foreach ( $_POST as $key => $value ) {
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
File wp-ldp.php
has 500 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
/**
* The WP-LDP Plugin main file
* @package WPLDP
* @author Benoit Alessandroni
Function wpldp_plugin_update
has a Cognitive Complexity of 29 (exceeds 5 allowed). Consider refactoring. Open
function wpldp_plugin_update() {
$plugin_version = get_option( 'wpldp_version' );
$update_option = null;
if ( self::$version_number !== $plugin_version ) {
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
WpLdp
has 21 functions (exceeds 20 allowed). Consider refactoring. Open
class WpLdp {
/**
* The front page url, defaulted as 'wp-ldp/front'.
*/
Method save_ldp_meta_for_post
has 52 lines of code (exceeds 25 allowed). Consider refactoring. Open
public function save_ldp_meta_for_post( $resource_id ) {
$fields = Utils::get_resource_fields_list( $resource_id );
if ( ! empty( $fields ) ) {
foreach ( $_POST as $key => $value ) {
Method wpldp_plugin_update
has 50 lines of code (exceeds 25 allowed). Consider refactoring. Open
function wpldp_plugin_update() {
$plugin_version = get_option( 'wpldp_version' );
$update_option = null;
if ( self::$version_number !== $plugin_version ) {
Method ldp_enqueue_script
has 47 lines of code (exceeds 25 allowed). Consider refactoring. Open
public function ldp_enqueue_script() {
global $pagenow, $post_type;
$screen = get_current_screen();
if ( Wpldp::RESOURCE_POST_TYPE === $post_type ) {
wp_enqueue_media();
Method wpldpfront_enqueue_script
has 40 lines of code (exceeds 25 allowed). Consider refactoring. Open
public function wpldpfront_enqueue_script() {
$current_url = $_SERVER['REQUEST_URI'];
if ( strstr( $current_url, Wpldp::FRONT_PAGE_URL ) ) {
// Loading the JqueryUI library.
wp_register_script(
Function wpldp_db_upgrade
has a Cognitive Complexity of 13 (exceeds 5 allowed). Consider refactoring. Open
private function wpldp_db_upgrade() {
$flush_cache = wp_cache_flush();
global $wpdb;
$wpdb->query(
"UPDATE $wpdb->postmeta
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Method wpldp_edit_form_advanced
has 39 lines of code (exceeds 25 allowed). Consider refactoring. Open
public function wpldp_edit_form_advanced( $post ) {
if ( Wpldp::RESOURCE_POST_TYPE === $post->post_type ) {
$resource_uri = Utils::get_resource_uri( $post );
$term = get_the_terms( $post->post_id, 'ldp_container' );
Function wpldp_edit_form_advanced
has a Cognitive Complexity of 12 (exceeds 5 allowed). Consider refactoring. Open
public function wpldp_edit_form_advanced( $post ) {
if ( Wpldp::RESOURCE_POST_TYPE === $post->post_type ) {
$resource_uri = Utils::get_resource_uri( $post );
$term = get_the_terms( $post->post_id, 'ldp_container' );
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Method create_ldp_type
has 30 lines of code (exceeds 25 allowed). Consider refactoring. Open
public function create_ldp_type() {
register_post_type( 'ldp_resource',
array(
'labels' => array(
'name' => __( 'Resources', 'wpldp' ),
Method wpldp_db_upgrade
has 29 lines of code (exceeds 25 allowed). Consider refactoring. Open
private function wpldp_db_upgrade() {
$flush_cache = wp_cache_flush();
global $wpdb;
$wpdb->query(
"UPDATE $wpdb->postmeta
Method container_meta_box_callback
has 27 lines of code (exceeds 25 allowed). Consider refactoring. Open
function container_meta_box_callback( $post ) {
wp_nonce_field(
'wpldp_save_container_box_data',
'wpldp_container_box_nonce'
);
Function ldp_resource_post_link
has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring. Open
function ldp_resource_post_link( $post_link, $id = 0 ) {
$post = get_post( $id );
if ( Wpldp::RESOURCE_POST_TYPE === get_post_type( $post ) ) {
if ( is_object( $post ) ) {
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Avoid deeply nested control flow statements. Open
if ( empty( $term ) || ! is_array( $term ) ) {
$site_url_parsed = wp_parse_url( $site );
$term = wp_insert_term(
$site_url_parsed['host'] . ' ' . $site_url_parsed['path'],
'ldp_site'
Function container_meta_box_callback
has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open
function container_meta_box_callback( $post ) {
wp_nonce_field(
'wpldp_save_container_box_data',
'wpldp_container_box_nonce'
);
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Function generate_menu_item
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
public static function generate_menu_item() {
$menu_name = 'primary';
$locations = get_nav_menu_locations();
if ( ! empty( $locations ) && isset( $locations[ $menu_name ] ) ) {
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
"require_once" is a statement not a function; no parentheses are required Open
require_once( 'class-container-taxonomy.php' );
- Exclude checks
"require_once" is a statement not a function; no parentheses are required Open
require_once( 'class-site-taxonomy.php' );
- Exclude checks
The parameter """" at position #2 of load_plugin_textdomain() has been deprecated since WordPress version 2.7.0. Use "" instead. Open
load_plugin_textdomain( 'wpldp', "", $path );
- Exclude checks
Visibility must be declared on method "display_container_meta_box" Open
function display_container_meta_box( $post_type ) {
- Exclude checks
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found '$term'. Open
<input id="in-ldp_container-<?php echo $term->term_id; ?>" type="radio" name="tax_input[ldp_container][]" value="<?php echo $term->term_id; ?>" checked>
- Exclude checks
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found '__'. Open
<p><?php echo __( 'If you need to upload a media during your editing, click here.', 'wpldp' ); ?></p>
- Exclude checks
Equals sign not aligned correctly; expected 1 space but found 8 spaces Open
$path = dirname( plugin_basename( __FILE__ ) ) . '/languages';
- Exclude checks
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found '$resource_uri'. Open
wpldp.render('#ldpform', '<?php echo $resource_uri; ?>', undefined, undefined, '<?php echo $term[0]->slug; ?>');
- Exclude checks
Resource version not set in call to wp_register_script(). This means new versions of the script will not always be loaded due to browser caching. Open
wp_register_script(
- Exclude checks
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found '$term'. Open
<input id="in-ldp_container-<?php echo $term->term_id; ?>" type="radio" name="tax_input[ldp_container][]" value="<?php echo $term->term_id; ?>">
- Exclude checks
Resource version not set in call to wp_register_script(). This means new versions of the script will not always be loaded due to browser caching. Open
wp_register_script(
- Exclude checks
In footer ($in_footer) is not set explicitly wp_register_script; It is recommended to load scripts in the footer. Please set this value to true
to load it in the footer, or explicitly false
if it should be loaded in the header. Open
wp_register_script(
- Exclude checks
Resource version not set in call to wp_register_script(). This means new versions of the script will not always be loaded due to browser caching. Open
wp_register_script(
- Exclude checks
Resource version not set in call to wp_register_style(). This means new versions of the style will not always be loaded due to browser caching. Open
wp_register_style(
- Exclude checks
Direct database call without caching detected. Consider using wp_cache_get() / wp_cache_set() or wp_cache_delete(). Open
$wpdb->query(
- Exclude checks
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found '$ldp_model'. Open
models: <?php echo $ldp_model; ?>
- Exclude checks
In footer ($in_footer) is not set explicitly wp_register_script; It is recommended to load scripts in the footer. Please set this value to true
to load it in the footer, or explicitly false
if it should be loaded in the header. Open
wp_register_script(
- Exclude checks
In footer ($in_footer) is not set explicitly wp_register_script; It is recommended to load scripts in the footer. Please set this value to true
to load it in the footer, or explicitly false
if it should be loaded in the header. Open
wp_register_script(
- Exclude checks
Resource version not set in call to wp_register_script(). This means new versions of the script will not always be loaded due to browser caching. Open
wp_register_script(
- Exclude checks
There must be exactly one blank line before the tags in a doc comment Open
* @package WPLDP
- Exclude checks
Equals sign not aligned with surrounding assignments; expected 4 spaces but found 1 space Open
$project_term = get_term_by( 'slug', 'project', 'ldp_container' );
- Exclude checks
Direct database call without caching detected. Consider using wp_cache_get() / wp_cache_set() or wp_cache_delete(). Open
$wpdb->query(
- Exclude checks
Opening PHP tag must be on a line by itself Open
</a><?php
- Exclude checks
Equals sign not aligned with surrounding assignments; expected 12 spaces but found 1 space Open
$term = wp_insert_term(
- Exclude checks
In footer ($in_footer) is not set explicitly wp_register_script; It is recommended to load scripts in the footer. Please set this value to true
to load it in the footer, or explicitly false
if it should be loaded in the header. Open
wp_register_script(
- Exclude checks
In footer ($in_footer) is not set explicitly wp_register_script; It is recommended to load scripts in the footer. Please set this value to true
to load it in the footer, or explicitly false
if it should be loaded in the header. Open
wp_register_script(
- Exclude checks
In footer ($in_footer) is not set explicitly wp_register_script; It is recommended to load scripts in the footer. Please set this value to true
to load it in the footer, or explicitly false
if it should be loaded in the header. Open
wp_register_script(
- Exclude checks
Class file names should be based on the class name with "class-" prepended. Expected class-wpldp.php, but found wp-ldp.php. Wontfix
<?php
- Exclude checks
"require_once" is a statement not a function; no parentheses are required Open
require_once( 'class-api.php' );
- Exclude checks
Usage of a direct database call is discouraged. Open
$wpdb->query(
- Exclude checks
Visibility must be declared on method "container_meta_box_callback" Open
function container_meta_box_callback( $post ) {
- Exclude checks
Equals sign not aligned with surrounding assignments; expected 3 spaces but found 1 space Open
$term_id = $term[0]->term_id;
- Exclude checks
In footer ($in_footer) is not set explicitly wp_register_script; It is recommended to load scripts in the footer. Please set this value to true
to load it in the footer, or explicitly false
if it should be loaded in the header. Open
wp_register_script(
- Exclude checks
String "" does not require double quotes; use single quotes instead Open
load_plugin_textdomain( 'wpldp', "", $path );
- Exclude checks
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found '$term'. Open
<input id="in-ldp_container-<?php echo $term->term_id; ?>" type="radio" name="tax_input[ldp_container][]" value="<?php echo $term->term_id; ?>">
- Exclude checks
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found '$term'. Open
<?php echo $term->name; ?>
- Exclude checks
Usage of a direct database call is discouraged. Open
$wpdb->query(
- Exclude checks
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found 'get_option'. Open
context: "<?php echo get_option( 'ldp_context', 'http://lov.okfn.org/dataset/lov/context' ); ?>",
- Exclude checks
In footer ($in_footer) is not set explicitly wp_register_script; It is recommended to load scripts in the footer. Please set this value to true
to load it in the footer, or explicitly false
if it should be loaded in the header. Open
wp_register_script(
- Exclude checks
Resource version not set in call to wp_register_script(). This means new versions of the script will not always be loaded due to browser caching. Open
wp_register_script(
- Exclude checks
Detected usage of a non-sanitized input variable: $_SERVER Open
$current_url = $_SERVER['REQUEST_URI'];
- Exclude checks
Resource version not set in call to wp_register_style(). This means new versions of the style will not always be loaded due to browser caching. Open
wp_register_style(
- Exclude checks
Visibility must be declared on method "load_translations_file" Open
function load_translations_file() {
- Exclude checks
Detected usage of a non-validated input variable: $_SERVER Open
$current_url = $_SERVER['REQUEST_URI'];
- Exclude checks
Resource version not set in call to wp_register_script(). This means new versions of the script will not always be loaded due to browser caching. Open
wp_register_script(
- Exclude checks
In footer ($in_footer) is not set explicitly wp_register_script; It is recommended to load scripts in the footer. Please set this value to true
to load it in the footer, or explicitly false
if it should be loaded in the header. Open
wp_register_script(
- Exclude checks
Missing wp_unslash() before sanitization. Open
$current_url = $_SERVER['REQUEST_URI'];
- Exclude checks
Array double arrow not aligned correctly; expected 1 space(s) between "'show_in_admin_bar'" and double arrow, but found 5. Open
'show_in_admin_bar' => true,
- Exclude checks
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found '$term'. Open
template: "{{{form '<?php echo $term[0]->slug; ?>'}}}",
- Exclude checks
Detected usage of meta_query, possible slow query. Open
'meta_query' => array(
- Exclude checks
In footer ($in_footer) is not set explicitly wp_register_script; It is recommended to load scripts in the footer. Please set this value to true
to load it in the footer, or explicitly false
if it should be loaded in the header. Open
wp_register_script(
- Exclude checks
Resource version not set in call to wp_register_script(). This means new versions of the script will not always be loaded due to browser caching. Open
wp_register_script(
- Exclude checks
In footer ($in_footer) is not set explicitly wp_register_script; It is recommended to load scripts in the footer. Please set this value to true
to load it in the footer, or explicitly false
if it should be loaded in the header. Open
wp_register_script(
- Exclude checks
Resource version not set in call to wp_register_style(). This means new versions of the style will not always be loaded due to browser caching. Open
wp_register_style(
- Exclude checks
Usage of a direct database call is discouraged. Open
$result = $wpdb->get_results(
- Exclude checks
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found '$resource_uri'. Open
container: '<?php echo $resource_uri; ?>',
- Exclude checks
In footer ($in_footer) is not set explicitly wp_register_script; It is recommended to load scripts in the footer. Please set this value to true
to load it in the footer, or explicitly false
if it should be loaded in the header. Open
wp_register_script(
- Exclude checks
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found '$term'. Open
wpldp.render('#ldpform', '<?php echo $resource_uri; ?>', undefined, undefined, '<?php echo $term[0]->slug; ?>');
- Exclude checks
Detected usage of a non-validated input variable: $_SERVER Open
$current_url = $_SERVER['REQUEST_URI'];
- Exclude checks
Processing form data without nonce verification. Open
foreach ( $_POST as $key => $value ) {
- Exclude checks
Resource version not set in call to wp_register_script(). This means new versions of the script will not always be loaded due to browser caching. Open
wp_register_script(
- Exclude checks
Resource version not set in call to wp_register_style(). This means new versions of the style will not always be loaded due to browser caching. Open
wp_register_style(
- Exclude checks
"require_once" is a statement not a function; no parentheses are required Open
require_once( 'class-settings.php' );
- Exclude checks
Array double arrow not aligned correctly; expected 7 space(s) between "'description'" and double arrow, but found 11. Open
'description' => __( 'LDP Resource', 'wpldp' ),
- Exclude checks
Missing wp_unslash() before sanitization. Open
$current_url = $_SERVER['REQUEST_URI'];
- Exclude checks
Equals sign not aligned with surrounding assignments; expected 2 spaces but found 1 space Open
$update_option = null;
- Exclude checks
Array double arrow not aligned correctly; expected 7 space(s) between "'has_archive'" and double arrow, but found 11. Open
'has_archive' => true,
- Exclude checks
Opening PHP tag must be on a line by itself Open
?><ul><?php
- Exclude checks
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found '$term'. Open
<li id="ldp_container-<?php echo $term->term_id; ?>" class="category">
- Exclude checks
Resource version not set in call to wp_register_style(). This means new versions of the style will not always be loaded due to browser caching. Open
wp_register_style(
- Exclude checks
Resource version not set in call to wp_register_style(). This means new versions of the style will not always be loaded due to browser caching. Open
wp_register_style(
- Exclude checks
Missing short description in doc comment Open
/**
- Exclude checks
Array double arrow not aligned correctly; expected 12 space(s) between "'public'" and double arrow, but found 16. Open
'public' => true,
- Exclude checks
Array double arrow not aligned correctly; expected 6 space(s) between "'show_in_menu'" and double arrow, but found 10. Open
'show_in_menu' => true,
- Exclude checks
Array double arrow not aligned correctly; expected 10 space(s) between "'supports'" and double arrow, but found 14. Open
'supports' => array(
- Exclude checks
All output should be run through an escaping function (see the Security sections in the WordPress Developer Handbooks), found '$term'. Open
<input id="in-ldp_container-<?php echo $term->term_id; ?>" type="radio" name="tax_input[ldp_container][]" value="<?php echo $term->term_id; ?>" checked>
- Exclude checks
Visibility must be declared on method "display_media_meta_box" Open
function display_media_meta_box( $post_type ) {
- Exclude checks
json_encode() is discouraged. Use wp_json_encode() instead. Open
$ldp_model = json_encode( json_decode( $term_meta['ldp_model'] ) );
- Exclude checks
Resource version not set in call to wp_register_script(). This means new versions of the script will not always be loaded due to browser caching. Open
wp_register_script(
- Exclude checks
Resource version not set in call to wp_register_script(). This means new versions of the script will not always be loaded due to browser caching. Open
wp_register_script(
- Exclude checks
Visibility must be declared on method "wpldp_plugin_update" Open
function wpldp_plugin_update() {
- Exclude checks
Array double arrow not aligned correctly; expected 9 space(s) between "'menu_icon'" and double arrow, but found 13. Open
'menu_icon' => 'dashicons-image-filter',
- Exclude checks
Opening PHP tag must be on a line by itself Open
</ul><?php
- Exclude checks
Resource version not set in call to wp_register_script(). This means new versions of the script will not always be loaded due to browser caching. Open
wp_register_script(
- Exclude checks
Resource version not set in call to wp_register_script(). This means new versions of the script will not always be loaded due to browser caching. Open
wp_register_script(
- Exclude checks
"require_once" is a statement not a function; no parentheses are required Open
require_once( 'class-utils.php' );
- Exclude checks
Equals sign not aligned with surrounding assignments; expected 2 spaces but found 1 space Open
$actor_term = get_term_by( 'slug', 'actor', 'ldp_container' );
- Exclude checks
Direct database call without caching detected. Consider using wp_cache_get() / wp_cache_set() or wp_cache_delete(). Open
$result = $wpdb->get_results(
- Exclude checks
Array double arrow not aligned correctly; expected 12 space(s) between "'labels'" and double arrow, but found 2. Open
'labels' => array(
- Exclude checks
Array double arrow not aligned correctly; expected 2 space(s) between "'show_in_nav_menu'" and double arrow, but found 6. Open
'show_in_nav_menu' => true,
- Exclude checks
Array double arrow not aligned correctly; expected 11 space(s) between "'rewrite'" and double arrow, but found 15. Open
'rewrite' => array(
- Exclude checks
Visibility must be declared on method "ldp_resource_post_link" Open
function ldp_resource_post_link( $post_link, $id = 0 ) {
- Exclude checks
Found precision alignment of 2 spaces. Open
strpos( $site, 'https://' ) !== false )
- Exclude checks
Resource version not set in call to wp_register_script(). This means new versions of the script will not always be loaded due to browser caching. Open
wp_register_script(
- Exclude checks
Detected usage of a non-sanitized input variable: $_SERVER Open
$current_url = $_SERVER['REQUEST_URI'];
- Exclude checks
In footer ($in_footer) is not set explicitly wp_register_script; It is recommended to load scripts in the footer. Please set this value to true
to load it in the footer, or explicitly false
if it should be loaded in the header. Open
wp_register_script(
- Exclude checks
Space found before semicolon; expected "];" but found "] ;" Open
$menu_id = $locations[ $menu_name ] ;
- Exclude checks
Equals sign not aligned with surrounding assignments; expected 3 spaces but found 1 space Open
$locations = get_nav_menu_locations();
- Exclude checks
Space found before semicolon; expected "];" but found "] ;" Open
$menu_id = $locations[ $menu_name ] ;
- Exclude checks
Array double arrow not aligned correctly; expected 3 space(s) between "'menu-item-title'" and double arrow, but found 1. Open
'menu-item-title' => __( 'Ecosystem', 'wpldp' ),
- Exclude checks
Array double arrow not aligned correctly; expected 5 space(s) between "'menu-item-url'" and double arrow, but found 1. Open
'menu-item-url' => home_url( Wpldp::FRONT_PAGE_URL, 'relative' ),
- Exclude checks
Equals sign not aligned with surrounding assignments; expected 3 spaces but found 1 space Open
$menu_name = 'primary';
- Exclude checks
Array double arrow not aligned correctly; expected 2 space(s) between "'menu-item-status'" and double arrow, but found 1. Open
'menu-item-status' => 'publish',
- Exclude checks
Equals sign not aligned with surrounding assignments; expected 7 spaces but found 1 space Open
$items = wp_get_nav_menu_items( $menu_id );
- Exclude checks
Equals sign not aligned with surrounding assignments; expected 5 spaces but found 1 space Open
$menu_id = $locations[ $menu_name ] ;
- Exclude checks
Line indented incorrectly; expected 0 tabs, found 3 Open
foreach ( $terms as $term ) {
- Exclude checks