bcit-ci/CodeIgniter

View on GitHub

Showing 876 of 876 total issues

Identical blocks of code found in 5 locations. Consider refactoring.
Open

    public function field_data($table)
    {
        if (($query = $this->query('SHOW COLUMNS FROM '.$this->protect_identifiers($table, TRUE, NULL, FALSE))) === FALSE)
        {
            return FALSE;
system/database/drivers/cubrid/cubrid_driver.php on lines 332..356
system/database/drivers/mysql/mysql_driver.php on lines 418..442
system/database/drivers/mysqli/mysqli_driver.php on lines 457..481
system/database/drivers/pdo/subdrivers/pdo_mysql_driver.php on lines 310..334

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 212.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Identical blocks of code found in 5 locations. Consider refactoring.
Open

    public function field_data($table)
    {
        if (($query = $this->query('SHOW COLUMNS FROM '.$this->protect_identifiers($table, TRUE, NULL, FALSE))) === FALSE)
        {
            return FALSE;
Severity: Major
Found in system/database/drivers/pdo/subdrivers/pdo_mysql_driver.php and 4 other locations - About 1 day to fix
system/database/drivers/cubrid/cubrid_driver.php on lines 332..356
system/database/drivers/mysql/mysql_driver.php on lines 418..442
system/database/drivers/mysqli/mysqli_driver.php on lines 457..481
system/database/drivers/pdo/subdrivers/pdo_cubrid_driver.php on lines 145..169

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 212.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Method create_captcha has 209 lines of code (exceeds 25 allowed). Consider refactoring.
Open

    function create_captcha($data = '', $img_path = '', $img_url = '', $font_path = '')
    {
        $defaults = array(
            'word'        => '',
            'img_path'    => '',
Severity: Major
Found in system/helpers/captcha_helper.php - About 1 day to fix

    Function create_links has a Cognitive Complexity of 52 (exceeds 5 allowed). Consider refactoring.
    Open

        public function create_links()
        {
            // If our item count or per-page total is zero there is no need to continue.
            // Note: DO NOT change the operator to === here!
            if ($this->total_rows == 0 OR $this->per_page == 0)
    Severity: Minor
    Found in system/libraries/Pagination.php - About 1 day to fix

    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

    Similar blocks of code found in 6 locations. Consider refactoring.
    Open

        public function field_data($table)
        {
            $sql = 'SELECT "column_name", "data_type", "character_maximum_length", "numeric_precision", "column_default"
                FROM "information_schema"."columns"
                WHERE LOWER("table_name") = '.$this->escape(strtolower($table));
    Severity: Major
    Found in system/database/drivers/postgre/postgre_driver.php and 5 other locations - About 1 day to fix
    system/database/drivers/mssql/mssql_driver.php on lines 312..335
    system/database/drivers/pdo/subdrivers/pdo_dblib_driver.php on lines 200..223
    system/database/drivers/pdo/subdrivers/pdo_pgsql_driver.php on lines 269..292
    system/database/drivers/pdo/subdrivers/pdo_sqlsrv_driver.php on lines 224..247
    system/database/drivers/sqlsrv/sqlsrv_driver.php on lines 330..353

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 204.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 6 locations. Consider refactoring.
    Open

        public function field_data($table)
        {
            $sql = 'SELECT COLUMN_NAME, DATA_TYPE, CHARACTER_MAXIMUM_LENGTH, NUMERIC_PRECISION, COLUMN_DEFAULT
                FROM INFORMATION_SCHEMA.Columns
                WHERE UPPER(TABLE_NAME) = '.$this->escape(strtoupper($table));
    system/database/drivers/mssql/mssql_driver.php on lines 312..335
    system/database/drivers/pdo/subdrivers/pdo_dblib_driver.php on lines 200..223
    system/database/drivers/pdo/subdrivers/pdo_pgsql_driver.php on lines 269..292
    system/database/drivers/postgre/postgre_driver.php on lines 437..460
    system/database/drivers/sqlsrv/sqlsrv_driver.php on lines 330..353

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 204.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 6 locations. Consider refactoring.
    Open

        public function field_data($table)
        {
            $sql = 'SELECT COLUMN_NAME, DATA_TYPE, CHARACTER_MAXIMUM_LENGTH, NUMERIC_PRECISION, COLUMN_DEFAULT
                FROM INFORMATION_SCHEMA.Columns
                WHERE UPPER(TABLE_NAME) = '.$this->escape(strtoupper($table));
    Severity: Major
    Found in system/database/drivers/pdo/subdrivers/pdo_dblib_driver.php and 5 other locations - About 1 day to fix
    system/database/drivers/mssql/mssql_driver.php on lines 312..335
    system/database/drivers/pdo/subdrivers/pdo_pgsql_driver.php on lines 269..292
    system/database/drivers/pdo/subdrivers/pdo_sqlsrv_driver.php on lines 224..247
    system/database/drivers/postgre/postgre_driver.php on lines 437..460
    system/database/drivers/sqlsrv/sqlsrv_driver.php on lines 330..353

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 204.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 6 locations. Consider refactoring.
    Open

        public function field_data($table)
        {
            $sql = 'SELECT "column_name", "data_type", "character_maximum_length", "numeric_precision", "column_default"
                FROM "information_schema"."columns"
                WHERE LOWER("table_name") = '.$this->escape(strtolower($table));
    Severity: Major
    Found in system/database/drivers/pdo/subdrivers/pdo_pgsql_driver.php and 5 other locations - About 1 day to fix
    system/database/drivers/mssql/mssql_driver.php on lines 312..335
    system/database/drivers/pdo/subdrivers/pdo_dblib_driver.php on lines 200..223
    system/database/drivers/pdo/subdrivers/pdo_sqlsrv_driver.php on lines 224..247
    system/database/drivers/postgre/postgre_driver.php on lines 437..460
    system/database/drivers/sqlsrv/sqlsrv_driver.php on lines 330..353

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 204.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 6 locations. Consider refactoring.
    Open

        public function field_data($table)
        {
            $sql = 'SELECT COLUMN_NAME, DATA_TYPE, CHARACTER_MAXIMUM_LENGTH, NUMERIC_PRECISION, COLUMN_DEFAULT
                FROM INFORMATION_SCHEMA.Columns
                WHERE UPPER(TABLE_NAME) = '.$this->escape(strtoupper($table));
    Severity: Major
    Found in system/database/drivers/sqlsrv/sqlsrv_driver.php and 5 other locations - About 1 day to fix
    system/database/drivers/mssql/mssql_driver.php on lines 312..335
    system/database/drivers/pdo/subdrivers/pdo_dblib_driver.php on lines 200..223
    system/database/drivers/pdo/subdrivers/pdo_pgsql_driver.php on lines 269..292
    system/database/drivers/pdo/subdrivers/pdo_sqlsrv_driver.php on lines 224..247
    system/database/drivers/postgre/postgre_driver.php on lines 437..460

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 204.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 6 locations. Consider refactoring.
    Open

        public function field_data($table)
        {
            $sql = 'SELECT COLUMN_NAME, DATA_TYPE, CHARACTER_MAXIMUM_LENGTH, NUMERIC_PRECISION, COLUMN_DEFAULT
                FROM INFORMATION_SCHEMA.Columns
                WHERE UPPER(TABLE_NAME) = '.$this->escape(strtoupper($table));
    Severity: Major
    Found in system/database/drivers/mssql/mssql_driver.php and 5 other locations - About 1 day to fix
    system/database/drivers/pdo/subdrivers/pdo_dblib_driver.php on lines 200..223
    system/database/drivers/pdo/subdrivers/pdo_pgsql_driver.php on lines 269..292
    system/database/drivers/pdo/subdrivers/pdo_sqlsrv_driver.php on lines 224..247
    system/database/drivers/postgre/postgre_driver.php on lines 437..460
    system/database/drivers/sqlsrv/sqlsrv_driver.php on lines 330..353

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 204.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 2 locations. Consider refactoring.
    Open

    window.SphinxRtdTheme = (function (jquery) {
        var stickyNav = (function () {
            var navBar,
                win,
                stickyNavCssClass = 'stickynav',
    user_guide_src/source/_themes/sphinx_rtd_theme/static/js/theme.js on lines 103..131

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 195.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 2 locations. Consider refactoring.
    Open

    window.SphinxRtdTheme = (function (jquery) {
        var stickyNav = (function () {
            var navBar,
                    win,
                    stickyNavCssClass = 'stickynav',
    user_guide_src/source/_themes/sphinx_rtd_theme/static/js/oldtheme.js on lines 19..47

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 195.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    CI_DB_driver has 55 functions (exceeds 20 allowed). Consider refactoring.
    Open

    abstract class CI_DB_driver {
    
        /**
         * Data Source Name / Connect string
         *
    Severity: Major
    Found in system/database/DB_driver.php - About 7 hrs to fix

      Identical blocks of code found in 2 locations. Consider refactoring.
      Open

          protected function _alter_table($alter_type, $table, $field)
          {
              if (in_array($alter_type, array('DROP', 'ADD'), TRUE))
              {
                  return parent::_alter_table($alter_type, $table, $field);
      Severity: Major
      Found in system/database/drivers/pdo/subdrivers/pdo_cubrid_forge.php and 1 other location - About 7 hrs to fix
      system/database/drivers/cubrid/cubrid_forge.php on lines 105..128

      Duplicated Code

      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

      Tuning

      This issue has a mass of 198.

      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

      Refactorings

      Further Reading

      Identical blocks of code found in 2 locations. Consider refactoring.
      Open

          protected function _alter_table($alter_type, $table, $field)
          {
              if (in_array($alter_type, array('DROP', 'ADD'), TRUE))
              {
                  return parent::_alter_table($alter_type, $table, $field);
      Severity: Major
      Found in system/database/drivers/cubrid/cubrid_forge.php and 1 other location - About 7 hrs to fix
      system/database/drivers/pdo/subdrivers/pdo_cubrid_forge.php on lines 105..128

      Duplicated Code

      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

      Tuning

      This issue has a mass of 198.

      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

      Refactorings

      Further Reading

      Function DB has a Cognitive Complexity of 49 (exceeds 5 allowed). Consider refactoring.
      Open

      function &DB($params = '', $query_builder_override = NULL)
      {
          // Load the DB config file if a DSN string wasn't passed
          if (is_string($params) && strpos($params, '://') === FALSE)
          {
      Severity: Minor
      Found in system/database/DB.php - About 7 hrs to fix

      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

      File Security.php has 481 lines of code (exceeds 250 allowed). Consider refactoring.
      Open

      <?php
      /**
       * CodeIgniter
       *
       * An open source application development framework for PHP
      Severity: Minor
      Found in system/core/Security.php - About 7 hrs to fix

        CI_Form_validation has 53 functions (exceeds 20 allowed). Consider refactoring.
        Open

        class CI_Form_validation {
        
            /**
             * Reference to the CodeIgniter instance
             *
        Severity: Major
        Found in system/libraries/Form_validation.php - About 7 hrs to fix

          Identical blocks of code found in 2 locations. Consider refactoring.
          Open

              public function drop_database($db_name)
              {
                  // In SQLite, a database is dropped when we delete a file
                  if (file_exists($this->db->database))
                  {
          Severity: Major
          Found in system/database/drivers/sqlite3/sqlite3_forge.php and 1 other location - About 7 hrs to fix
          system/database/drivers/pdo/subdrivers/pdo_sqlite_forge.php on lines 119..143

          Duplicated Code

          Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

          Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

          When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

          Tuning

          This issue has a mass of 193.

          We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

          The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

          If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

          See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

          Refactorings

          Further Reading

          Identical blocks of code found in 2 locations. Consider refactoring.
          Open

              public function drop_database($db_name)
              {
                  // In SQLite, a database is dropped when we delete a file
                  if (file_exists($this->db->database))
                  {
          Severity: Major
          Found in system/database/drivers/pdo/subdrivers/pdo_sqlite_forge.php and 1 other location - About 7 hrs to fix
          system/database/drivers/sqlite3/sqlite3_forge.php on lines 105..129

          Duplicated Code

          Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

          Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

          When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

          Tuning

          This issue has a mass of 193.

          We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

          The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

          If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

          See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

          Refactorings

          Further Reading

          Severity
          Category
          Status
          Source
          Language