talho/openphin

View on GitHub

Showing 3,486 of 3,486 total issues

Function onNodeOver has a Cognitive Complexity of 28 (exceeds 5 allowed). Consider refactoring.
Open

    onNodeOver : function(n, dd, e, data){
        var pt = this.getDropPoint(e, n, dd);
        var node = n.node;
        
        // auto node expand check
Severity: Minor
Found in app/assets/javascripts/ext/src/widgets/tree/TreeDropZone.js - About 4 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

Function renderCellTreeUI has a Cognitive Complexity of 28 (exceeds 5 allowed). Consider refactoring.
Open

    renderCellTreeUI : function(record, store)
    {
        var tpl = this.templates.treeui,
            line_tpl = this.templates.elbow_line,
            tpl_data = {},
Severity: Minor
Found in app/assets/javascripts/ext_extensions/TreeGrid/src/GridView.js - About 4 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

Function renderCellTreeUI has a Cognitive Complexity of 28 (exceeds 5 allowed). Consider refactoring.
Open

    renderCellTreeUI : function(record, store)
    {
        var tpl = this.templates.treeui,
            line_tpl = this.templates.elbow_line,
            tpl_data = {},
Severity: Minor
Found in app/assets/javascripts/ext_extensions/TreeGrid/TreeGrid.js - About 4 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

Method create has a Cognitive Complexity of 28 (exceeds 5 allowed). Consider refactoring.
Open

  def create
    jurisdiction = Jurisdiction.find(params[:role_assigns][:jurisdiction_id]) unless params[:role_assigns][:jurisdiction_id].blank?
    if jurisdiction.nil?
      flash[:error] = "No jurisdiction was specified"
      redirect_to new_role_assignment_path
Severity: Minor
Found in app/controllers/admin/role_assignments_controller.rb - About 4 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

Method processAcknowledgmentStatus has a Cognitive Complexity of 28 (exceeds 5 allowed). Consider refactoring.
Open

  def processAcknowledgmentStatus alert, rcptStatus = nil, time_offset = 0
    return false if rcptStatus.nil? || rcptStatus['id'].blank?

    user = User.find_by_id(rcptStatus['id'])
    if user.nil?
Severity: Minor
Found in lib/workers/query_swn_for_acknowledgments_worker.rb - About 4 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

Function DragDropTabs has 102 lines of code (exceeds 25 allowed). Consider refactoring.
Open

Ext.plugin.DragDropTabs = (function() {
    var TabProxy = Ext.extend(Ext.dd.StatusProxy, {
        constructor: function(config) {
            TabProxy.superclass.constructor.call(this, config);
            // Custom class needed on the proxy so the tab can
Severity: Major
Found in app/assets/javascripts/ext_extensions/DragDropTabs.js - About 4 hrs to fix

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

                    if ( status == "success" ) {
                        // Cache Last-Modified header, if ifModified mode.
                        var modRes;
                        try {
                            modRes = xhr.getResponseHeader("Last-Modified");
    Severity: Major
    Found in app/assets/javascripts/jquery.js and 1 other location - About 4 hrs to fix
    app/assets/javascripts/jquery-tooltip/lib/jquery.js on lines 2698..2712

    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 116.

    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

        createInnerElements: function() {
            var target = this.layout.innerCt;
            
            //normal items will be rendered to the innerCt. beforeCt and afterCt allow for fixed positioning of
            //special items such as scrollers or dropdown menu triggers
    app/assets/javascripts/ext/src/widgets/layout/box/ScrollerOverflow.js on lines 441..452

    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 116.

    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

        createInnerElements: function() {
            var target = this.layout.innerCt;
            
            //normal items will be rendered to the innerCt. beforeCt and afterCt allow for fixed positioning of
            //special items such as scrollers or dropdown menu triggers
    app/assets/javascripts/ext/src/widgets/layout/box/ScrollerOverflow.js on lines 351..362

    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 116.

    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

                    if ( status == "success" ) {
                        // Cache Last-Modified header, if ifModified mode.
                        var modRes;
                        try {
                            modRes = xml.getResponseHeader("Last-Modified");
    Severity: Major
    Found in app/assets/javascripts/jquery-tooltip/lib/jquery.js and 1 other location - About 4 hrs to fix
    app/assets/javascripts/jquery.js on lines 3590..3604

    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 116.

    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 Anim has 101 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

    Ext.lib.Anim = function(){
        var createAnim = function(cb, scope){
            var animated = true;
            return {
                stop : function(skipToLast){
    Severity: Major
    Found in app/assets/javascripts/ext/src/adapter/jquery-bridge.js - About 4 hrs to fix

      Function Anim has 101 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

      Ext.lib.Anim = function(){
          var createAnim = function(cb, scope){
              var animated = true;
              return {
                  stop : function(skipToLast){
      Severity: Major
      Found in app/assets/javascripts/ext/adapter/jquery/ext-jquery-adapter-debug.js - About 4 hrs to fix

        Function constructor has 100 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

          constructor: function(config){
            this.pageSize = 10;
            this.store = new Ext.data.GroupingStore({
              autoLoad: {params: {start: 0, limit: this.pageSize}}, autoSave: false,
              restful: true,
        Severity: Major
        Found in app/assets/javascripts/admin/EditUsers.js - About 4 hrs to fix

          Consider simplifying this complex logical expression.
          Open

                      if ( typeof elem === "string" ) {
                          // Fix "XHTML"-style tags in all browsers
                          elem = elem.replace(/(<(\w+)[^>]*?)\/>/g, function(all, front, tag){
                              return tag.match(/^(abbr|br|col|img|input|link|meta|param|hr|area|embed)$/i) ?
                                  all :
          Severity: Critical
          Found in app/assets/javascripts/jquery.js - About 4 hrs to fix

            Field has 32 functions (exceeds 20 allowed). Consider refactoring.
            Open

            Ext.form.Field = Ext.extend(Ext.BoxComponent,  {
                /**
                 * <p>The label Element associated with this Field. <b>Only available after this Field has been rendered by a
                 * {@link form Ext.layout.FormLayout} layout manager.</b></p>
                 * @type Ext.Element
            Severity: Minor
            Found in app/assets/javascripts/ext/src/widgets/form/Field.js - About 4 hrs to fix

              Container has 32 functions (exceeds 20 allowed). Consider refactoring.
              Open

              Ext.Container = Ext.extend(Ext.BoxComponent, {
                  /**
                   * @cfg {Boolean} monitorResize
                   * True to automatically monitor window resize events to handle anything that is sensitive to the current size
                   * of the viewport.  This value is typically managed by the chosen <code>{@link #layout}</code> and should not need
              Severity: Minor
              Found in app/assets/javascripts/ext/src/widgets/Container.js - About 4 hrs to fix

                Consider simplifying this complex logical expression.
                Open

                            if ( typeof elem == "string" ) {
                                // Fix "XHTML"-style tags in all browsers
                                elem = elem.replace(/(<(\w+)[^>]*?)\/>/g, function(all, front, tag){
                                    return tag.match(/^(abbr|br|col|img|input|link|meta|param|hr|area|embed)$/i) ?
                                        all :
                Severity: Critical
                Found in app/assets/javascripts/jquery-tooltip/lib/jquery.js - About 4 hrs to fix

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

                  if(Ext.DatePicker){
                     Ext.apply(Ext.DatePicker.prototype, {
                        todayText         : "오늘",
                        minText           : "최소 날짜범위를 넘었습니다.",
                        maxText           : "최대 날짜범위를 넘었습니다.",
                  Severity: Major
                  Found in app/assets/javascripts/ext/src/locale/ext-lang-ko.js and 28 other locations - About 4 hrs to fix
                  app/assets/javascripts/ext/src/locale/ext-lang-bg.js on lines 97..115
                  app/assets/javascripts/ext/src/locale/ext-lang-ca.js on lines 100..118
                  app/assets/javascripts/ext/src/locale/ext-lang-cs.js on lines 121..139
                  app/assets/javascripts/ext/src/locale/ext-lang-da.js on lines 107..125
                  app/assets/javascripts/ext/src/locale/ext-lang-de.js on lines 115..133
                  app/assets/javascripts/ext/src/locale/ext-lang-en.js on lines 104..122
                  app/assets/javascripts/ext/src/locale/ext-lang-en_GB.js on lines 100..118
                  app/assets/javascripts/ext/src/locale/ext-lang-es.js on lines 103..121
                  app/assets/javascripts/ext/src/locale/ext-lang-fa.js on lines 92..110
                  app/assets/javascripts/ext/src/locale/ext-lang-fr.js on lines 121..139
                  app/assets/javascripts/ext/src/locale/ext-lang-he.js on lines 103..121
                  app/assets/javascripts/ext/src/locale/ext-lang-hr.js on lines 107..125
                  app/assets/javascripts/ext/src/locale/ext-lang-hu.js on lines 107..125
                  app/assets/javascripts/ext/src/locale/ext-lang-id.js on lines 112..130
                  app/assets/javascripts/ext/src/locale/ext-lang-it.js on lines 105..123
                  app/assets/javascripts/ext/src/locale/ext-lang-ja.js on lines 103..121
                  app/assets/javascripts/ext/src/locale/ext-lang-lt.js on lines 118..136
                  app/assets/javascripts/ext/src/locale/ext-lang-nl.js on lines 108..126
                  app/assets/javascripts/ext/src/locale/ext-lang-no_NB.js on lines 105..123
                  app/assets/javascripts/ext/src/locale/ext-lang-no_NN.js on lines 105..123
                  app/assets/javascripts/ext/src/locale/ext-lang-pt.js on lines 80..98
                  app/assets/javascripts/ext/src/locale/ext-lang-pt_BR.js on lines 122..140
                  app/assets/javascripts/ext/src/locale/ext-lang-pt_PT.js on lines 100..118
                  app/assets/javascripts/ext/src/locale/ext-lang-ro.js on lines 105..123
                  app/assets/javascripts/ext/src/locale/ext-lang-ru.js on lines 119..137
                  app/assets/javascripts/ext/src/locale/ext-lang-th.js on lines 105..123
                  app/assets/javascripts/ext/src/locale/ext-lang-tr.js on lines 119..137
                  app/assets/javascripts/ext/src/locale/ext-lang-ukr.js on lines 81..99

                  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 115.

                  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 29 locations. Consider refactoring.
                  Open

                  if(Ext.DatePicker){
                      Ext.apply(Ext.DatePicker.prototype, {
                          todayText         : "Aujourd'hui",
                          minText           : "Cette date est antérieure à la date minimum",
                          maxText           : "Cette date est postérieure à la date maximum",
                  Severity: Major
                  Found in app/assets/javascripts/ext/src/locale/ext-lang-fr.js and 28 other locations - About 4 hrs to fix
                  app/assets/javascripts/ext/src/locale/ext-lang-bg.js on lines 97..115
                  app/assets/javascripts/ext/src/locale/ext-lang-ca.js on lines 100..118
                  app/assets/javascripts/ext/src/locale/ext-lang-cs.js on lines 121..139
                  app/assets/javascripts/ext/src/locale/ext-lang-da.js on lines 107..125
                  app/assets/javascripts/ext/src/locale/ext-lang-de.js on lines 115..133
                  app/assets/javascripts/ext/src/locale/ext-lang-en.js on lines 104..122
                  app/assets/javascripts/ext/src/locale/ext-lang-en_GB.js on lines 100..118
                  app/assets/javascripts/ext/src/locale/ext-lang-es.js on lines 103..121
                  app/assets/javascripts/ext/src/locale/ext-lang-fa.js on lines 92..110
                  app/assets/javascripts/ext/src/locale/ext-lang-he.js on lines 103..121
                  app/assets/javascripts/ext/src/locale/ext-lang-hr.js on lines 107..125
                  app/assets/javascripts/ext/src/locale/ext-lang-hu.js on lines 107..125
                  app/assets/javascripts/ext/src/locale/ext-lang-id.js on lines 112..130
                  app/assets/javascripts/ext/src/locale/ext-lang-it.js on lines 105..123
                  app/assets/javascripts/ext/src/locale/ext-lang-ja.js on lines 103..121
                  app/assets/javascripts/ext/src/locale/ext-lang-ko.js on lines 77..95
                  app/assets/javascripts/ext/src/locale/ext-lang-lt.js on lines 118..136
                  app/assets/javascripts/ext/src/locale/ext-lang-nl.js on lines 108..126
                  app/assets/javascripts/ext/src/locale/ext-lang-no_NB.js on lines 105..123
                  app/assets/javascripts/ext/src/locale/ext-lang-no_NN.js on lines 105..123
                  app/assets/javascripts/ext/src/locale/ext-lang-pt.js on lines 80..98
                  app/assets/javascripts/ext/src/locale/ext-lang-pt_BR.js on lines 122..140
                  app/assets/javascripts/ext/src/locale/ext-lang-pt_PT.js on lines 100..118
                  app/assets/javascripts/ext/src/locale/ext-lang-ro.js on lines 105..123
                  app/assets/javascripts/ext/src/locale/ext-lang-ru.js on lines 119..137
                  app/assets/javascripts/ext/src/locale/ext-lang-th.js on lines 105..123
                  app/assets/javascripts/ext/src/locale/ext-lang-tr.js on lines 119..137
                  app/assets/javascripts/ext/src/locale/ext-lang-ukr.js on lines 81..99

                  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 115.

                  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 29 locations. Consider refactoring.
                  Open

                  if(Ext.DatePicker){
                     Ext.apply(Ext.DatePicker.prototype, {
                        todayText         : "Hoje",
                        minText           : "Esta data &eacute; anterior &agrave; menor data",
                        maxText           : "Esta data &eacute; posterior &agrave; maior data",
                  Severity: Major
                  Found in app/assets/javascripts/ext/src/locale/ext-lang-pt.js and 28 other locations - About 4 hrs to fix
                  app/assets/javascripts/ext/src/locale/ext-lang-bg.js on lines 97..115
                  app/assets/javascripts/ext/src/locale/ext-lang-ca.js on lines 100..118
                  app/assets/javascripts/ext/src/locale/ext-lang-cs.js on lines 121..139
                  app/assets/javascripts/ext/src/locale/ext-lang-da.js on lines 107..125
                  app/assets/javascripts/ext/src/locale/ext-lang-de.js on lines 115..133
                  app/assets/javascripts/ext/src/locale/ext-lang-en.js on lines 104..122
                  app/assets/javascripts/ext/src/locale/ext-lang-en_GB.js on lines 100..118
                  app/assets/javascripts/ext/src/locale/ext-lang-es.js on lines 103..121
                  app/assets/javascripts/ext/src/locale/ext-lang-fa.js on lines 92..110
                  app/assets/javascripts/ext/src/locale/ext-lang-fr.js on lines 121..139
                  app/assets/javascripts/ext/src/locale/ext-lang-he.js on lines 103..121
                  app/assets/javascripts/ext/src/locale/ext-lang-hr.js on lines 107..125
                  app/assets/javascripts/ext/src/locale/ext-lang-hu.js on lines 107..125
                  app/assets/javascripts/ext/src/locale/ext-lang-id.js on lines 112..130
                  app/assets/javascripts/ext/src/locale/ext-lang-it.js on lines 105..123
                  app/assets/javascripts/ext/src/locale/ext-lang-ja.js on lines 103..121
                  app/assets/javascripts/ext/src/locale/ext-lang-ko.js on lines 77..95
                  app/assets/javascripts/ext/src/locale/ext-lang-lt.js on lines 118..136
                  app/assets/javascripts/ext/src/locale/ext-lang-nl.js on lines 108..126
                  app/assets/javascripts/ext/src/locale/ext-lang-no_NB.js on lines 105..123
                  app/assets/javascripts/ext/src/locale/ext-lang-no_NN.js on lines 105..123
                  app/assets/javascripts/ext/src/locale/ext-lang-pt_BR.js on lines 122..140
                  app/assets/javascripts/ext/src/locale/ext-lang-pt_PT.js on lines 100..118
                  app/assets/javascripts/ext/src/locale/ext-lang-ro.js on lines 105..123
                  app/assets/javascripts/ext/src/locale/ext-lang-ru.js on lines 119..137
                  app/assets/javascripts/ext/src/locale/ext-lang-th.js on lines 105..123
                  app/assets/javascripts/ext/src/locale/ext-lang-tr.js on lines 119..137
                  app/assets/javascripts/ext/src/locale/ext-lang-ukr.js on lines 81..99

                  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 115.

                  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