Showing 3,246 of 4,217 total issues
Method __construct
has 60 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function __construct($type = 'user', $no_db_connect = false, $auto_init_all = false, $_conf = [])
{
if ( ! isset($this->_time_start)) {
$this->_time_start = microtime(true);
}
Method _update_config
has 60 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function _update_config($name = '', $no_indexing = false, $no_write = false)
{
$conf_file_path = $this->CONF_PATH . 'sphinx.conf';
if (file_exists($conf_file_path) && ! is_readable($conf_file_path)) {
return _e('Error!. File ' . $conf_file_path . ' is not readable! Please check permissions.');
Method tip
has 60 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function tip($in = null, $extra = [])
{
if ( ! is_array($extra)) {
$extra = [];
}
Method test_with_data_full
has 60 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function test_with_data_full()
{
$data = [
[
'date' => strtotime('2014-08-12 12:03:19 UTC'),
Method _currency_rate_load
has 59 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
protected function _currency_rate_load($options = null)
{
// import options
is_array($options) && extract($options, EXTR_PREFIX_ALL | EXTR_REFS, '');
// var
Method _init
has 59 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function _init()
{
if ( ! $this->ENABLE) {
return null;
}
Method _get_users_daily_payments
has 59 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function _get_users_daily_payments($user_ids = [], $type = 'sum')
{
if ( ! $user_ids) {
return false;
}
Method _get_time_diff_human
has 59 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function _get_time_diff_human($seconds, $delimiter = ' ', $need_return = false, $only_text = false, $need_closing_tag = false)
{
$d = [];
$tr = [
'years' => ['лет', 'год', 'года'],
Method upload_dir
has 59 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function upload_dir($server_info = [], $local_dir = '', $remote_dir = '', $pattern_include = '', $pattern_exclude = '', $level = null)
{
$local_dir = _class('ssh')->_prepare_path($local_dir);
$remote_dir = _class('ssh')->_prepare_path($remote_dir);
if ( ! _class('ssh')->_INIT_OK || ! $server_info || ! strlen($local_dir) || ! strlen($remote_dir)) {
Method test_get_and_limit
has 59 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function test_get_and_limit()
{
if ($this->_need_skip_test(__FUNCTION__)) {
return;
}
Method test_join
has 59 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function test_join()
{
if ($this->_need_skip_test(__FUNCTION__)) {
return;
}
File test_globals_vs_class.php
has 264 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
<?php
function globals_var($name, $value = null)
{
if ( ! isset($name)) {
Consider simplifying this complex logical expression. Open
Open
if ($in_string) {
for (;;) {
$i = strpos($sql, $string_start, $i);
// No end of string found -> add the current substring to the
// returned array
yf_db_driver_pgsql
has 22 functions (exceeds 20 allowed). Consider refactoring. Open
Open
class yf_db_driver_pgsql extends yf_db_driver
{
/** @var @conf_skip */
public $db_connect_id = null;
yf_wrapper_redis
has 22 functions (exceeds 20 allowed). Consider refactoring. Open
Open
class yf_wrapper_redis
{
public $name = 'REDIS'; // instance name
public $driver = 'phpredis'; // predis|phpredis
yf_manage_shop__product_revisions
has 22 functions (exceeds 20 allowed). Consider refactoring. Open
Open
class yf_manage_shop__product_revisions
{
public $temp_fields = [
'product' => ['image', 'add_date', 'update_date', 'last_viewed_date', 'viewed', 'sold', 'status', 'origin_url', 'source', 'featured'],
'orders' => [],
class_db_real_migrator_mysql_test
has 22 functions (exceeds 20 allowed). Consider refactoring. Open
Open
class class_db_real_migrator_mysql_test extends db_real_abstract
{
public static function db_name()
{
return self::$DB_NAME;
Method date_box
has 58 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function date_box($selected = '', $years = '', $name_postfix = '', $add_str = '', $show_what = 'ymd', $show_text = 1, $translate = 1)
{
if (is_array($selected)) {
$extra = (array) $extra + $name;
$selected = $extra['selected'];
Method date_box2
has 58 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function date_box2($name, $selected = '', $years = '', $add_str = '', $show_what = 'ymd', $show_text = 1, $translate = 1)
{
if (is_array($selected)) {
$extra = (array) $extra + $name;
$name = $extra['name'];
Method _form_options
has 58 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function _form_options($options)
{
if ( ! $this->ENABLE) {
return null;
}