Showing 5,566 of 7,504 total issues
Function wpmu_validate_blog_signup
has a Cognitive Complexity of 23 (exceeds 5 allowed). Consider refactoring. Open
function wpmu_validate_blog_signup( $blogname, $blog_title, $user = '' ) {
global $wpdb, $domain;
$current_site = get_current_site();
$base = $current_site->path;
- 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 get_permalink
has a Cognitive Complexity of 23 (exceeds 5 allowed). Consider refactoring. Open
function get_permalink($id = 0, $leavename = false) {
$rewritecode = array(
'%year%',
'%monthnum%',
'%day%',
- 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 start_el
has a Cognitive Complexity of 23 (exceeds 5 allowed). Consider refactoring. Open
function start_el(&$output, $category, $depth, $args) {
extract($args);
$cat_name = esc_attr( $category->name);
$cat_name = apply_filters( 'list_cats', $cat_name, $category );
- 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 editor_plugin.dev.js
has 302 lines of code (exceeds 250 allowed). Consider refactoring. Open
/**
* WordPress plugin.
*/
(function() {
File module.tag.id3v1.php
has 302 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
/////////////////////////////////////////////////////////////////
/// getID3() by James Heinrich <info@getid3.org> //
// available at http://getid3.sourceforge.net //
// or http://www.getid3.org //
Function _setupReorderUI
has 81 lines of code (exceeds 25 allowed). Consider refactoring. Open
_setupReorderUI: function() {
var self = this, selectSidebarItem, $moveWidgetArea,
$reorderNav, updateAvailableSidebars;
/**
Function addToolbar
has 81 lines of code (exceeds 25 allowed). Consider refactoring. Open
function addToolbar(items) {
var toolbarItems = [], buttonGroup;
if (!items) {
return;
Method install_theme_information
has 81 lines of code (exceeds 25 allowed). Consider refactoring. Open
function install_theme_information() {
//TODO: This function needs a LOT of UI work :)
global $tab, $themes_allowedtags;
$api = themes_api('theme_information', array('slug' => stripslashes( $_REQUEST['theme'] ) ));
Method convert_categories
has 81 lines of code (exceeds 25 allowed). Consider refactoring. Open
function convert_categories() {
global $wpdb;
if ( (!isset($_POST['cats_to_convert']) || !is_array($_POST['cats_to_convert'])) && empty($this->categories_to_convert)) { ?>
<div class="narrow">
Method mw_getPost
has 81 lines of code (exceeds 25 allowed). Consider refactoring. Open
function mw_getPost($args) {
$this->escape($args);
$post_ID = (int) $args[0];
Method customize_register
has 81 lines of code (exceeds 25 allowed). Consider refactoring. Open
public function customize_register() {
global $wp_registered_widgets, $wp_registered_widget_controls, $wp_registered_sidebars;
$sidebars_widgets = array_merge(
array( 'wp_inactive_widgets' => array() ),
File MySQL.php
has 301 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
/**
* SimplePie
*
* A PHP-Based RSS and Atom Feed Framework.
Function init
has 80 lines of code (exceeds 25 allowed). Consider refactoring. Open
init: function() {
var toolbar;
s.toolbar = toolbar = $('#fullscreen-topbar');
s.$fullscreenFader = $('#fullscreen-fader');
Function renderInlineUI
has 80 lines of code (exceeds 25 allowed). Consider refactoring. Open
function renderInlineUI(args) {
var panel, inlineToolbarContainer;
if (settings.fixed_toolbar_container) {
inlineToolbarContainer = DOM.select(settings.fixed_toolbar_container)[0];
Method extractByIndex
has 80 lines of code (exceeds 25 allowed). Consider refactoring. Open
function extractByIndex($p_index)
{
$v_result=1;
// ----- Reset the error handler
Method __construct
has 80 lines of code (exceeds 25 allowed). Consider refactoring. Open
function __construct() {
$this->methods = array(
// WordPress API
'wp.getUsersBlogs' => 'this:wp_getUsersBlogs',
'wp.newPost' => 'this:wp_newPost',
Method paged_walk
has 80 lines of code (exceeds 25 allowed). Consider refactoring. Open
function paged_walk( $elements, $max_depth, $page_num, $per_page ) {
/* sanity check */
if ( empty($elements) || $max_depth < -1 )
return '';
Method paged_walk
has 80 lines of code (exceeds 25 allowed). Consider refactoring. Open
function paged_walk( $elements, $max_depth, $page_num, $per_page ) {
/* sanity check */
if ( empty($elements) || $max_depth < -1 )
return '';
SimplePie_IRI
has 27 functions (exceeds 20 allowed). Consider refactoring. Open
class SimplePie_IRI
{
/**
* Scheme
*
Class TournamentQueries
has 27 methods (exceeds 20 allowed). Consider refactoring. Open
public class TournamentQueries : BaseReadModel<TournamentQueries>,
IReadModel,
ITournamentQueries,
ISubscribeTo<TournamentCreated>,
ISubscribeTo<ChangeNotificationCutoffChanged>,