e107inc/e107

View on GitHub

Showing 6,972 of 6,973 total issues

Consider simplifying this complex logical expression.
Open

             if ((in_array($key, $columnPref) || ($key === 'options' && isset($val['title'])) || (vartrue($val['forced']))) && !vartrue($val['nolist']))
            {
                $cl = (vartrue($val['thclass'])) ? " class='".$val['thclass']."'" : '';

                $aClass = ($key === $field) ? "sorted-" . $sorted : null;
Severity: Major
Found in e107_handlers/form_handler.php - About 40 mins to fix

    Consider simplifying this complex logical expression.
    Open

            if($table && !$where && is_bool($fields))
            {
                // table is the query, fields used for multi
                if($fields)
                {
    Severity: Major
    Found in e107_handlers/e_db_pdo_class.php - About 40 mins to fix

      Consider simplifying this complex logical expression.
      Open

              if($field['type'] === 'method' && !empty($field['data']) && ($field['data'] === 'string' || $field['data'] === 'str' || $field['data'] === 'safestr' || $field['data'] === 'int'))
              {
                  $searchable_types[] = 'method';
              }
      Severity: Major
      Found in e107_handlers/admin_ui.php - About 40 mins to fix

        Consider simplifying this complex logical expression.
        Open

                if((!empty($parm) && !empty($mandatory[$parm]) && (int) $pref[$mandatory[$parm]] === 2) || $parm === 'true' || ($parm === 'email' && empty($pref['disable_emailcheck'])))
                {
                    return "<span class='required'><!-- empty --></span>";
                }
        Severity: Major
        Found in e107_core/shortcodes/batch/signup_shortcodes.php - About 40 mins to fix

          Consider simplifying this complex logical expression.
          Open

                          if (!array_key_exists($uc_id,$this->fixed_classes)
                          && (   getperms('0')
                              || (
                                  (!isset($opt_arr['matchclass']) || check_class($uc_id))
                                  &&
          Severity: Major
          Found in e107_handlers/userclass_class.php - About 40 mins to fix

            Consider simplifying this complex logical expression.
            Open

                        if((isset($_POST['e-token']) && !$this->checkFormToken($_POST['e-token']))
                        || (isset($_GET['e-token']) && !$this->checkFormToken($_GET['e-token']))
                        || (isset($_POST['e_token']) && !$this->checkFormToken($_POST['e_token']))) // '-' is not allowed in jquery. b
                        {
                            $this->log('Unauthorized access!');
            Severity: Major
            Found in e107_handlers/session_handler.php - About 40 mins to fix

              Consider simplifying this complex logical expression.
              Open

                  if($def == 'legacyCustom' || $def=='legacyDefault' )  // 0.6 themes.
                  {
                    //    echo "MODE 0.6";
                      if($def == 'legacyCustom')
                      {
              Severity: Major
              Found in e107_core/templates/header_default.php - About 40 mins to fix

                Consider simplifying this complex logical expression.
                Open

                                    if((!strpos($pref['download_denied'], ".php") &&
                                        !strpos($pref['download_denied'], ".htm") &&
                                        !strpos($pref['download_denied'], ".html") &&
                                        !strpos($pref['download_denied'], ".shtml") ||
                                        (strpos($pref['download_denied'], "signup.php") && USER == true)
                Severity: Major
                Found in e107_plugins/download/request.php - About 40 mins to fix

                  Consider simplifying this complex logical expression.
                  Open

                          if ((isset($_POST['newthread']) && trim($_POST['subject']) == '') || trim($_POST['post']) == '')
                          {
                              message_handler('ALERT', 5);
                          }
                          else
                  Severity: Major
                  Found in e107_plugins/forum/forum_post.php - About 40 mins to fix

                    Method parsesearch has 8 arguments (exceeds 7 allowed). Consider refactoring.
                    Open

                        public function parsesearch($table, $return_fields, $search_fields, $weights, $handler, $no_results, $where, $order)
                    Severity: Major
                    Found in e107_handlers/search_class.php - About 35 mins to fix

                      Method form_password has 8 arguments (exceeds 7 allowed). Consider refactoring.
                      Open

                          public function form_password($form_name, $form_size, $form_value, $form_maxlength = FALSE, $form_class = 'tbox form-control', $form_readonly = '', $form_tooltip = '', $form_js = '') {
                      Severity: Major
                      Found in e107_handlers/form_handler.php - About 35 mins to fix

                        Method form_text has 8 arguments (exceeds 7 allowed). Consider refactoring.
                        Open

                            public function form_text($form_name, $form_size, $form_value, $form_maxlength = FALSE, $form_class = 'tbox form-control', $form_readonly = '', $form_tooltip = '', $form_js = '') {
                        Severity: Major
                        Found in e107_handlers/form_handler.php - About 35 mins to fix

                          Method renderInline has 8 arguments (exceeds 7 allowed). Consider refactoring.
                          Open

                              public function renderInline($dbField, $pid, $fieldName, $curVal, $linkText, $type='text', $array=null, $options=array())
                          Severity: Major
                          Found in e107_handlers/form_handler.php - About 35 mins to fix

                            Method e_log_event has 8 arguments (exceeds 7 allowed). Consider refactoring.
                            Open

                                public function e_log_event($importance, $source_call, $eventcode = 'GEN', $event_title = 'Untitled', $explain = '', $finished = FALSE, $target_logs = LOG_TO_AUDIT, $userData=null )
                            Severity: Major
                            Found in e107_handlers/admin_log_class.php - About 35 mins to fix

                              Method addEvent has 8 arguments (exceeds 7 allowed). Consider refactoring.
                              Open

                                  public function addEvent($importance, $source_call, $eventcode = 'GEN', $event_title = 'Untitled', $explain = '', $finished = FALSE, $target_logs = LOG_TO_AUDIT, $userData=null )
                              Severity: Major
                              Found in e107_handlers/admin_log_class.php - About 35 mins to fix

                                Method compose_comment has 8 arguments (exceeds 7 allowed). Consider refactoring.
                                Open

                                    function compose_comment($table, $action, $id, $width, $subject, $rate = FALSE, $return = FALSE, $tablerender = TRUE)
                                Severity: Major
                                Found in e107_handlers/comment_class.php - About 35 mins to fix

                                  Avoid too many return statements within this method.
                                  Open

                                                  if ($just_check) return update_needed('Menu path changed required:  '.$val['menu'].' ');
                                  Severity: Major
                                  Found in e107_admin/update_routines.php - About 30 mins to fix

                                    Avoid too many return statements within this method.
                                    Open

                                            if ($just_check) return update_needed('Core search handlers need to be updated.');
                                    Severity: Major
                                    Found in e107_admin/update_routines.php - About 30 mins to fix

                                      Avoid too many return statements within this method.
                                      Open

                                            if ($just_check) return update_needed();
                                      Severity: Major
                                      Found in e107_admin/update_routines.php - About 30 mins to fix

                                        Avoid too many return statements within this method.
                                        Open

                                                    return $ret;
                                        Severity: Major
                                        Found in e107_admin/lancheck.php - About 30 mins to fix
                                          Severity
                                          Category
                                          Status
                                          Source
                                          Language