Showing 3,246 of 4,217 total issues
Function _add_bundle
has a Cognitive Complexity of 26 (exceeds 5 allowed). Consider refactoring. Open
public function _add_bundle($_content, $_params = [])
{
if ( ! $_content) {
return false;
}
- 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 api_payout
has a Cognitive Complexity of 26 (exceeds 5 allowed). Consider refactoring. Open
public function api_payout($method, $options)
{
if ( ! $this->ENABLE) {
return null;
}
- 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 _delete
has a Cognitive Complexity of 26 (exceeds 5 allowed). Consider refactoring. Open
public function _delete($params = [])
{
if (empty(main()->USER_ID) && MAIN_TYPE_USER) {
return _error_need_login();
}
- 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 remote_file_size
has a Cognitive Complexity of 26 (exceeds 5 allowed). Consider refactoring. Open
public function remote_file_size($url = '')
{
$url = $this->_fix_url($url);
$tmp = @parse_url($url);
$sch = $tmp['scheme'];
- 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 multi_set
has a Cognitive Complexity of 26 (exceeds 5 allowed). Consider refactoring. Open
public function multi_set($data = [], $ttl = 0)
{
$do_real_work = true;
if ( ! $this->_driver_ok || $this->NO_CACHE) {
$do_real_work = false;
- 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 connect
has a Cognitive Complexity of 26 (exceeds 5 allowed). Consider refactoring. Open
public function connect()
{
$this->db_connect_id = mysqli_init();
if ( ! $this->db_connect_id || mysqli_connect_errno()) {
$this->_connect_error = 'cannot_connect_to_server';
- 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 del_by_prefix
has a Cognitive Complexity of 26 (exceeds 5 allowed). Consider refactoring. Open
public function del_by_prefix($prefix = '')
{
$do_real_work = true;
if ( ! $this->_driver_ok) {
$do_real_work = false;
- 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 _show_info_items
has a Cognitive Complexity of 26 (exceeds 5 allowed). Consider refactoring. Open
public function _show_info_items()
{
// Array of text fields
$text_fields = [
'name' => '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
Function products_show
has a Cognitive Complexity of 26 (exceeds 5 allowed). Consider refactoring. Open
public function products_show($search = '', $str_search = '')
{
foreach ((array) module('shop')->_shop_cats as $_cat_id => $_cat_name) {
if ($_GET['id'] == module('shop')->_shop_cats_all[$_cat_id]['url'] && $_GET['id'] != '') {
$_GET['id'] = $_cat_id;
- 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 attribute_edit
has a Cognitive Complexity of 26 (exceeds 5 allowed). Consider refactoring. Open
public function attribute_edit()
{
if (empty($_GET['id'])) {
return _e('no id');
}
- 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 _show_auto_table
has a Cognitive Complexity of 26 (exceeds 5 allowed). Consider refactoring. Open
public function _show_auto_table($items = [], $params = [], $name = '')
{
if ( ! is_array($items)) {
$items = [];
}
- 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 product_clone
has 93 lines of code (exceeds 25 allowed). Consider refactoring. Open
public function product_clone()
{
$_GET['id'] = (int) ($_GET['id']);
if ($_GET['id']) {
$a = $this->_get_product($_GET['id']);
File yf_manage_dashboards2.class.php
has 321 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
/**
* Dashboards2 management.
*
File yf_manage_currency.class.php
has 320 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
class yf_manage_currency
{
public $load_provider = [
Method _data
has 92 lines of code (exceeds 25 allowed). Consider refactoring. Open
public function _data($id)
{
if (strpos($id, ':')) {
$id = array_map([$this, 'id'], explode(':', $id));
return [
File sys_log_user_errors.sql_php.php
has 320 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
return [
'fields' => [
'id' => [
yf_db_utils_mysql
has 30 functions (exceeds 20 allowed). Consider refactoring. Open
class yf_db_utils_mysql extends yf_db_utils_driver
{
public function _get_supported_field_types()
{
return [
yf_db_driver_mysqli
has 30 functions (exceeds 20 allowed). Consider refactoring. Open
class yf_db_driver_mysqli extends yf_db_driver
{
/** @var @conf_skip */
public $db_connect_id = null;
/** @var string */
yf_dir
has 30 functions (exceeds 20 allowed). Consider refactoring. Open
class yf_dir
{
/** @var bool */
public $CHECK_IF_READABLE = true;
/** @var bool */
File yf_manage_faq.class.php
has 319 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
class yf_manage_faq
{
const table = 'faq';