Showing 4,217 of 4,217 total issues
Method split_sql
has 74 lines of code (exceeds 25 allowed). Consider refactoring. Open
public function split_sql($sql)
{
$out = [];
// do not trim
$sql = rtrim($sql, "\n\r");
Method query
has 74 lines of code (exceeds 25 allowed). Consider refactoring. Open
public function &query($sql)
{
if ( ! $this->_connected && ! $this->connect()) {
return false;
}
Method show_old
has 74 lines of code (exceeds 25 allowed). Consider refactoring. Open
public function show_old()
{
// Path to project.conf.php
$proj_conf_path = INCLUDE_PATH . 'project_conf.php';
Method _add_revision
has 74 lines of code (exceeds 25 allowed). Consider refactoring. Open
public function _add_revision($type, $action, $ids = false)
{
if (empty($ids) || empty($action) || empty($type)) {
return false;
}
Method _store_item
has 74 lines of code (exceeds 25 allowed). Consider refactoring. Open
public function _store_item($data = [])
{
if (is_string($data) && strlen($data)) {
$data = ['url' => $data];
}
Method search_used
has 73 lines of code (exceeds 25 allowed). Consider refactoring. Open
public function search_used()
{
$exclude_paths = [
'*/.git/*',
'*/.dev/*',
Method _show_block
has 73 lines of code (exceeds 25 allowed). Consider refactoring. Open
public function _show_block($input = [])
{
if ( ! isset($this->_blocks_infos)) {
$this->_blocks_infos = main()->get_data('blocks_all');
}
Method _get_methods
has 73 lines of code (exceeds 25 allowed). Consider refactoring. Open
public function _get_methods($params = [])
{
$ONLY_PRIVATE_METHODS = [];
if (isset($params['private'])) {
$ONLY_PRIVATE_METHODS = $params['private'];
Method generate_down
has 73 lines of code (exceeds 25 allowed). Consider refactoring. Open
public function generate_down($report = null, $params = [])
{
if ( ! isset($report)) {
$report = $this->compare($params);
}
Method connect
has 73 lines of code (exceeds 25 allowed). Consider refactoring. Open
public function connect($server_info = [])
{
if ( ! $this->_INIT_OK || ! $server_info) {
return false;
}
Method data_get_latest_currencies
has 73 lines of code (exceeds 25 allowed). Consider refactoring. Open
function data_get_latest_currencies()
{
$url = 'http://www.currency-iso.org/dam/downloads/table_a1.xml';
$f = __DIR__ . '/' . basename($url);
if (!file_exists($f)) {
Function select_box
has a Cognitive Complexity of 21 (exceeds 5 allowed). Consider refactoring. Open
public function select_box($name, $values = [], $selected = '', $show_text = false, $type = 2, $add_str = '', $translate = 0, $level = 0)
{
// Passing params as array
if (is_array($name)) {
$extra = (array) $extra + $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 _add_asset
has a Cognitive Complexity of 21 (exceeds 5 allowed). Consider refactoring. Open
public function _add_asset($_content, $asset_type, $_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 21 (exceeds 5 allowed). Consider refactoring. Open
public function api_payout($options = null)
{
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 provider
has a Cognitive Complexity of 21 (exceeds 5 allowed). Consider refactoring. Open
public function provider($options = null)
{
// import options
is_array($options) && extract($options, EXTR_PREFIX_ALL | EXTR_REFS, '');
// get providers
- 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 _form_options
has a Cognitive Complexity of 21 (exceeds 5 allowed). Consider refactoring. Open
public function _form_options($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 _operation_check
has a Cognitive Complexity of 21 (exceeds 5 allowed). Consider refactoring. Open
public function _operation_check($options = null)
{
$result = [];
$data = [];
// options
- 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 filter_save
has a Cognitive Complexity of 21 (exceeds 5 allowed). Consider refactoring. Open
public function filter_save($params = [])
{
if ( ! is_array($params)) {
$params = [];
}
- 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 21 (exceeds 5 allowed). Consider refactoring. Open
public function api_payout($options = null)
{
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 find_all_hooks
has a Cognitive Complexity of 21 (exceeds 5 allowed). Consider refactoring. Open
public function find_all_hooks($section = 'all')
{
if ( ! in_array($section, ['all', 'user', 'admin'])) {
$section = 'all';
}
- 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"