Showing 3,246 of 4,217 total issues
Method test_correct_protocol
has 39 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function test_correct_protocol()
{
$old = main()->USE_ONLY_HTTPS;
main()->USE_ONLY_HTTPS = true;
Method _filter_form_show
has 38 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function _filter_form_show($filter, $replace)
{
$order_fields = [];
foreach (explode('|', 'user_id|name|email|add_date|last_login|num_logins|active|balance|datetime_create|datetime_update') as $f) {
$order_fields[$f] = $f;
Method mass_cancel
has 38 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function mass_cancel($options = null)
{
$operation_id = $this->_get_operation_id($options);
is_numeric($operation_id) && $operation_id = [$operation_id => 1];
if ( ! is_array($operation_id)) {
Method _get_stpls_for_type
has 38 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function _get_stpls_for_type($type = 'user')
{
$theme_name = $type == 'admin' ? 'admin' : 'user';
$CACHE_NAME = 'stpls_list_for_' . $type;
Method _check_multi_accounts
has 38 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function _check_multi_accounts()
{
if (empty($_SESSION[$this->VAR_USER_ID]) || empty($_SESSION[$this->VAR_USER_GROUP_ID])) {
return false;
}
Method tbl_link_active
has 38 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function tbl_link_active($name = '', $link = '', $extra = [], $replace = [], $form)
{
if (is_array($name)) {
$extra = (array) $extra + $name;
$name = $extra['name'];
Method alter_table
has 38 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function alter_table($table_name, $column_name, $db)
{
if ( ! $this->get_lock()) {
return false;
}
Method _render_table_contents_rotated
has 38 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function _render_table_contents_rotated($data = [], $params, $to_hide = [])
{
$tbody_attrs = '';
if (isset($params['tbody'])) {
$tbody_attrs = is_array($params['tbody']) ? _attrs($params['tbody'], ['class', 'id']) : ' ' . $params['tbody'];
Method load_spiders_uas
has 38 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function load_spiders_uas()
{
$ext = '.txt';
$ext_len = strlen($ext);
$pattern = '{,plugins/*/}share/spiders/*' . $ext;
Method get_relative_path
has 38 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function get_relative_path($target, $fromdir)
{
// Check that the fromdir has a trailing slash, otherwise realpath will
// strip the last directory name off
if (($fromdir[strlen($fromdir) - 1] != '\\') && ($fromdir[strlen($fromdir) - 1] != '/')) {
Method products_xls_export
has 38 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function products_xls_export()
{
$old_supplier_id = '';
ini_set('memory_limit', '1024M');
$sql = $this->_sql();
Method set_main_image
has 38 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function set_main_image()
{
if ($_GET['id']) {
$product = module('manage_shop')->_product_get_info($_GET['id']);
}
Method _db_exists
has 38 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function _db_exists($name, $options = [])
{
$cache = &$this->cache;
$_ = $options;
$key = $_['key'];
Method _local_make_tar
has 38 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function _local_make_tar($files_list = [], $archive_path = '')
{
if (empty($files_list)) {
return false;
}
Method edit_locale_stpl
has 38 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function edit_locale_stpl()
{
no_graphics(true);
if ( ! DEBUG_MODE || ! tpl()->ALLOW_INLINE_DEBUG) {
return print 'Access denied';
Method _get_modules_from_files
has 38 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function _get_modules_from_files($include_framework = true, $with_sub_modules = false)
{
$modules = [];
$yf_prefix_len = strlen(YF_PREFIX);
Method category_revisions_view
has 38 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function category_revisions_view()
{
$type = 'category';
$db_revision = $this->get_revision_db($type);
$id = (int) $_GET['id'];
Method download_dir
has 38 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function download_dir($server_info = [], $remote_dir = '', $local_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 show_site_title
has 38 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function show_site_title()
{
if (defined('SITE_ADVERT_NAME')) {
$title = SITE_ADVERT_NAME;
}
Method test_one_to_one
has 38 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function test_one_to_one()
{
if ($this->_need_skip_test(__FUNCTION__)) {
return;
}