Showing 3,246 of 4,217 total issues
File yf_manage_shop.class.php
has 704 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
/**
* Shop managing module.
*/
File yf_manage_shop_orders.class.php
has 702 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
class yf_manage_shop_orders
{
public function _init()
yf_payment_api
has 85 functions (exceeds 20 allowed). Consider refactoring. Open
class yf_payment_api
{
public $user_id_default = null;
public $user_id = null;
File payment.data.php
has 696 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
return [
0 => [
'payment_id' => '22',
File rental.data.php
has 696 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
return [
0 => [
'rental_id' => '361',
Function _filter_sql_prepare
has a Cognitive Complexity of 79 (exceeds 5 allowed). Consider refactoring. Open
public function _filter_sql_prepare($filter_data = [], $filter_params = [], $__sql = '', $table = null)
{
if ( ! $filter_data) {
return '';
}
- 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 yf_manage_transfer.class.php
has 687 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
class yf_manage_transfer
{
public $payment_api = null;
File yf_payment_api__provider_perfectmoney.class.php
has 687 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
_class('payment_api__provider_remote');
class yf_payment_api__provider_perfectmoney extends yf_payment_api__provider_remote
File yf_aliases.php
has 687 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
///////////////////////////////////
// Aliases for often used methods
///////////////////////////////////
Function _try_to_find_libs
has a Cognitive Complexity of 78 (exceeds 5 allowed). Consider refactoring. Open
public function _try_to_find_libs()
{
if ( ! $this->AUTO_FIND_PATHS) {
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 _get_template_file
has a Cognitive Complexity of 77 (exceeds 5 allowed). Consider refactoring. Open
public function _get_template_file($file_name = '', $force_storage = '', $JUST_CHECK_IF_EXISTS = false, $RETURN_TEMPLATE_PATH = false)
{
$string = false;
$NOT_FOUND = false;
$storage = 'inline';
- 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 sample_html.class.php
has 675 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
class sample_html
{
/***/
yf_assets
has 81 functions (exceeds 20 allowed). Consider refactoring. Open
class yf_assets
{
/** @array */
public $supported_asset_types = [
'jquery', 'js', 'css', 'less', 'sass', 'coffee', 'bundle', 'asset', /*, 'img', 'font'*/
Method _api_transaction
has 303 lines of code (exceeds 25 allowed). Consider refactoring. Open
public function _api_transaction($options)
{
if ( ! $this->ENABLE) {
return null;
}
Function _go
has a Cognitive Complexity of 76 (exceeds 5 allowed). Consider refactoring. Open
public function _go($location, $rewrite = true, $redirect_type = 'hybrid', $text = '', $ttl = 3, $params = [])
{
if (is_array($location)) {
$params += $location;
$rewrite = isset($params['rewrite']) ? $params['rewrite'] : $rewrite;
- 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 yf_category_editor.class.php
has 666 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
/**
* Categories editor.
*
File sys_admin_modules.data.php
has 659 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
return [
2 => [
'id' => '2',
File user.sql_php.php
has 658 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
return [
'fields' => [
'id' => [
Function _get_modules_from_files
has a Cognitive Complexity of 73 (exceeds 5 allowed). Consider refactoring. Open
public function _get_modules_from_files($include_framework = true, $with_sub_modules = false)
{
$user_modules_array = [];
$pattern_include = '-f ~/' . preg_quote(USER_MODULES_DIR, '~') . '.*' . preg_quote(YF_CLS_EXT, '~') . '$~';
$pattern_no_submodules = '~/' . preg_quote(USER_MODULES_DIR, '~') . '[^/]+' . preg_quote(YF_CLS_EXT, '~') . '$~ims';
- 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 compare_table
has a Cognitive Complexity of 72 (exceeds 5 allowed). Consider refactoring. Open
public function compare_table($t1, $t2, $db_prefix)
{
$prefix_len = strlen($db_prefix);
$columns = [];
$indexes = [];
- 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"