Showing 4,217 of 4,217 total issues

Method test_yf_db_installer_create_missing_table has 39 lines of code (exceeds 25 allowed). Consider refactoring.
Open

    public function test_yf_db_installer_create_missing_table()
    {
        $bak['ERROR_AUTO_REPAIR'] = self::db()->ERROR_AUTO_REPAIR;
        self::db()->ERROR_AUTO_REPAIR = true;

    Method execute has 39 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

        protected function execute(InputInterface $input, OutputInterface $output)
        {
            global $yf_paths;
            require_once $yf_paths['db_setup_path'];
            init_yf();
    Severity: Minor
    Found in .dev/console/commands/yf_console_db_migrate.class.php - About 1 hr to fix

      Method test_sakila_basic has 39 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

          public function test_sakila_basic()
          {
              if ($this->_need_skip_test(__FUNCTION__)) {
                  return;
              }
      Severity: Minor
      Found in .dev/tests/functional/model/class_model_sakila_test.Test.php - About 1 hr to fix

        Method test_order7 has 39 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

            public function test_order7()
            {
                $jquery_url = _class('assets')->get_asset('jquery', 'js');
                $url = $jquery_url;
                $url1 = $url . '?v=1';
        Severity: Minor
        Found in .dev/tests/unit/class_assets_test.Test.php - About 1 hr to fix

          Method test_update_batch has 39 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

              public function test_update_batch()
              {
                  if ($this->_need_skip_test(__FUNCTION__)) {
                      return;
                  }
          Severity: Minor
          Found in .dev/tests/unit/db/class_db_offline_query_builder_test.Test.php - About 1 hr to fix

            Method test_correct_protocol has 39 lines of code (exceeds 25 allowed). Consider refactoring.
            Open

                public function test_correct_protocol()
                {
                    $old = main()->USE_ONLY_HTTPS;
                    main()->USE_ONLY_HTTPS = true;
            
            
            Severity: Minor
            Found in .dev/tests/rewrite/class_rewrite_testing_shared.php - About 1 hr to fix

              Method _filter_form_show has 38 lines of code (exceeds 25 allowed). Consider refactoring.
              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;
              Severity: Minor
              Found in plugins/payment/admin_modules/yf_manage_payment.class.php - About 1 hr to fix

                Method mass_cancel has 38 lines of code (exceeds 25 allowed). Consider refactoring.
                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)) {
                Severity: Minor
                Found in plugins/payment/admin_modules/yf_manage_payout.class.php - About 1 hr to fix

                  Method _get_stpls_for_type has 38 lines of code (exceeds 25 allowed). Consider refactoring.
                  Open

                      public function _get_stpls_for_type($type = 'user')
                      {
                          $theme_name = $type == 'admin' ? 'admin' : 'user';
                  
                          $CACHE_NAME = 'stpls_list_for_' . $type;
                  Severity: Minor
                  Found in plugins/tpl/admin_modules/yf_template_editor.class.php - About 1 hr to fix

                    Method _check_multi_accounts has 38 lines of code (exceeds 25 allowed). Consider refactoring.
                    Open

                        public function _check_multi_accounts()
                        {
                            if (empty($_SESSION[$this->VAR_USER_ID]) || empty($_SESSION[$this->VAR_USER_GROUP_ID])) {
                                return false;
                            }
                    Severity: Minor
                    Found in plugins/auth/classes/auth/yf_auth_user.class.php - About 1 hr to fix

                      Method tbl_link_active has 38 lines of code (exceeds 25 allowed). Consider refactoring.
                      Open

                          public function tbl_link_active($name = '', $link = '', $extra = [], $replace = [], $form)
                          {
                              if (is_array($name)) {
                                  $extra = (array) $extra + $name;
                                  $name = $extra['name'];
                      Severity: Minor
                      Found in plugins/form2/classes/form2/yf_form2_tbl_funcs.class.php - About 1 hr to fix

                        Method alter_table has 38 lines of code (exceeds 25 allowed). Consider refactoring.
                        Open

                            public function alter_table($table_name, $column_name, $db)
                            {
                                if ( ! $this->get_lock()) {
                                    return false;
                                }
                        Severity: Minor
                        Found in plugins/db/classes/db/yf_db_installer.class.php - About 1 hr to fix

                          Method _render_table_contents_rotated has 38 lines of code (exceeds 25 allowed). Consider refactoring.
                          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'];
                          Severity: Minor
                          Found in plugins/table2/classes/yf_table2.class.php - About 1 hr to fix

                            Method load_spiders_uas has 38 lines of code (exceeds 25 allowed). Consider refactoring.
                            Open

                                public function load_spiders_uas()
                                {
                                    $ext = '.txt';
                                    $ext_len = strlen($ext);
                                    $pattern = '{,plugins/*/}share/spiders/*' . $ext;
                            Severity: Minor
                            Found in plugins/common/classes/common/yf_spider_detection.class.php - About 1 hr to fix

                              Method get_relative_path has 38 lines of code (exceeds 25 allowed). Consider refactoring.
                              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] != '/')) {
                              Severity: Minor
                              Found in plugins/common/classes/common/yf_other_common.class.php - About 1 hr to fix

                                Method products_xls_export has 38 lines of code (exceeds 25 allowed). Consider refactoring.
                                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

                                      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

                                        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

                                          public function _local_make_tar($files_list = [], $archive_path = '')
                                          {
                                              if (empty($files_list)) {
                                                  return false;
                                              }
                                      Severity: Minor
                                      Found in plugins/ssh/classes/ssh/yf_ssh_tar.class.php - About 1 hr to fix

                                        Method edit_locale_stpl has 38 lines of code (exceeds 25 allowed). Consider refactoring.
                                        Open

                                            public function edit_locale_stpl()
                                            {
                                                no_graphics(true);
                                                if ( ! DEBUG_MODE || ! tpl()->ALLOW_INLINE_DEBUG) {
                                                    return print 'Access denied';
                                        Severity: Minor
                                        Found in plugins/dynamic/modules/dynamic/yf_dynamic_edit.class.php - About 1 hr to fix
                                          Severity
                                          Category
                                          Status
                                          Source
                                          Language