sibprogrammer/owp

View on GitHub

Showing 803 of 803 total issues

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

if(Ext.form.HtmlEditor){
  Ext.apply(Ext.form.HtmlEditor.prototype, {
    createLinkText : 'Add meg a webcímet:',
    buttonTips : {
      bold : {
Severity: Major
Found in public/ext/locale/ext-lang-hu.js and 30 other locations - About 1 day to fix
public/ext/locale/ext-lang-bg.js on lines 177..253
public/ext/locale/ext-lang-ca.js on lines 186..262
public/ext/locale/ext-lang-cs.js on lines 184..260
public/ext/locale/ext-lang-de.js on lines 196..272
public/ext/locale/ext-lang-el_GR.js on lines 198..274
public/ext/locale/ext-lang-en.js on lines 194..270
public/ext/locale/ext-lang-en_GB.js on lines 190..266
public/ext/locale/ext-lang-es.js on lines 189..265
public/ext/locale/ext-lang-fa.js on lines 171..247
public/ext/locale/ext-lang-fi.js on lines 189..265
public/ext/locale/ext-lang-fr.js on lines 211..287
public/ext/locale/ext-lang-he.js on lines 183..259
public/ext/locale/ext-lang-hr.js on lines 186..262
public/ext/locale/ext-lang-id.js on lines 193..269
public/ext/locale/ext-lang-it.js on lines 185..261
public/ext/locale/ext-lang-ja.js on lines 189..265
public/ext/locale/ext-lang-ko.js on lines 156..232
public/ext/locale/ext-lang-lt.js on lines 198..274
public/ext/locale/ext-lang-nl.js on lines 194..270
public/ext/locale/ext-lang-no_NB.js on lines 185..261
public/ext/locale/ext-lang-no_NN.js on lines 185..261
public/ext/locale/ext-lang-pl.js on lines 195..271
public/ext/locale/ext-lang-pt.js on lines 159..235
public/ext/locale/ext-lang-pt_BR.js on lines 201..277
public/ext/locale/ext-lang-pt_PT.js on lines 184..260
public/ext/locale/ext-lang-ro.js on lines 185..261
public/ext/locale/ext-lang-ru.js on lines 199..275
public/ext/locale/ext-lang-th.js on lines 185..261
public/ext/locale/ext-lang-tr.js on lines 197..273
public/ext/locale/ext-lang-ukr.js on lines 160..236

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

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

if(Ext.form.HtmlEditor){
  Ext.apply(Ext.form.HtmlEditor.prototype, {
    createLinkText : 'Vennligst skriv inn URL for lenken:',
    buttonTips : {
      bold : {
Severity: Major
Found in public/ext/locale/ext-lang-no_NB.js and 30 other locations - About 1 day to fix
public/ext/locale/ext-lang-bg.js on lines 177..253
public/ext/locale/ext-lang-ca.js on lines 186..262
public/ext/locale/ext-lang-cs.js on lines 184..260
public/ext/locale/ext-lang-de.js on lines 196..272
public/ext/locale/ext-lang-el_GR.js on lines 198..274
public/ext/locale/ext-lang-en.js on lines 194..270
public/ext/locale/ext-lang-en_GB.js on lines 190..266
public/ext/locale/ext-lang-es.js on lines 189..265
public/ext/locale/ext-lang-fa.js on lines 171..247
public/ext/locale/ext-lang-fi.js on lines 189..265
public/ext/locale/ext-lang-fr.js on lines 211..287
public/ext/locale/ext-lang-he.js on lines 183..259
public/ext/locale/ext-lang-hr.js on lines 186..262
public/ext/locale/ext-lang-hu.js on lines 187..263
public/ext/locale/ext-lang-id.js on lines 193..269
public/ext/locale/ext-lang-it.js on lines 185..261
public/ext/locale/ext-lang-ja.js on lines 189..265
public/ext/locale/ext-lang-ko.js on lines 156..232
public/ext/locale/ext-lang-lt.js on lines 198..274
public/ext/locale/ext-lang-nl.js on lines 194..270
public/ext/locale/ext-lang-no_NN.js on lines 185..261
public/ext/locale/ext-lang-pl.js on lines 195..271
public/ext/locale/ext-lang-pt.js on lines 159..235
public/ext/locale/ext-lang-pt_BR.js on lines 201..277
public/ext/locale/ext-lang-pt_PT.js on lines 184..260
public/ext/locale/ext-lang-ro.js on lines 185..261
public/ext/locale/ext-lang-ru.js on lines 199..275
public/ext/locale/ext-lang-th.js on lines 185..261
public/ext/locale/ext-lang-tr.js on lines 197..273
public/ext/locale/ext-lang-ukr.js on lines 160..236

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

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

if(Ext.form.HtmlEditor){
  Ext.apply(Ext.form.HtmlEditor.prototype, {
    createLinkText : 'Lütfen bu baðlantý için gerekli URL adresini giriniz:',
    buttonTips : {
      bold : {
Severity: Major
Found in public/ext/locale/ext-lang-tr.js and 30 other locations - About 1 day to fix
public/ext/locale/ext-lang-bg.js on lines 177..253
public/ext/locale/ext-lang-ca.js on lines 186..262
public/ext/locale/ext-lang-cs.js on lines 184..260
public/ext/locale/ext-lang-de.js on lines 196..272
public/ext/locale/ext-lang-el_GR.js on lines 198..274
public/ext/locale/ext-lang-en.js on lines 194..270
public/ext/locale/ext-lang-en_GB.js on lines 190..266
public/ext/locale/ext-lang-es.js on lines 189..265
public/ext/locale/ext-lang-fa.js on lines 171..247
public/ext/locale/ext-lang-fi.js on lines 189..265
public/ext/locale/ext-lang-fr.js on lines 211..287
public/ext/locale/ext-lang-he.js on lines 183..259
public/ext/locale/ext-lang-hr.js on lines 186..262
public/ext/locale/ext-lang-hu.js on lines 187..263
public/ext/locale/ext-lang-id.js on lines 193..269
public/ext/locale/ext-lang-it.js on lines 185..261
public/ext/locale/ext-lang-ja.js on lines 189..265
public/ext/locale/ext-lang-ko.js on lines 156..232
public/ext/locale/ext-lang-lt.js on lines 198..274
public/ext/locale/ext-lang-nl.js on lines 194..270
public/ext/locale/ext-lang-no_NB.js on lines 185..261
public/ext/locale/ext-lang-no_NN.js on lines 185..261
public/ext/locale/ext-lang-pl.js on lines 195..271
public/ext/locale/ext-lang-pt.js on lines 159..235
public/ext/locale/ext-lang-pt_BR.js on lines 201..277
public/ext/locale/ext-lang-pt_PT.js on lines 184..260
public/ext/locale/ext-lang-ro.js on lines 185..261
public/ext/locale/ext-lang-ru.js on lines 199..275
public/ext/locale/ext-lang-th.js on lines 185..261
public/ext/locale/ext-lang-ukr.js on lines 160..236

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

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

if(Ext.form.HtmlEditor){
  Ext.apply(Ext.form.HtmlEditor.prototype, {
    createLinkText : 'Indique o endereço do link:',
    buttonTips : {
      bold : {
Severity: Major
Found in public/ext/locale/ext-lang-pt_PT.js and 30 other locations - About 1 day to fix
public/ext/locale/ext-lang-bg.js on lines 177..253
public/ext/locale/ext-lang-ca.js on lines 186..262
public/ext/locale/ext-lang-cs.js on lines 184..260
public/ext/locale/ext-lang-de.js on lines 196..272
public/ext/locale/ext-lang-el_GR.js on lines 198..274
public/ext/locale/ext-lang-en.js on lines 194..270
public/ext/locale/ext-lang-en_GB.js on lines 190..266
public/ext/locale/ext-lang-es.js on lines 189..265
public/ext/locale/ext-lang-fa.js on lines 171..247
public/ext/locale/ext-lang-fi.js on lines 189..265
public/ext/locale/ext-lang-fr.js on lines 211..287
public/ext/locale/ext-lang-he.js on lines 183..259
public/ext/locale/ext-lang-hr.js on lines 186..262
public/ext/locale/ext-lang-hu.js on lines 187..263
public/ext/locale/ext-lang-id.js on lines 193..269
public/ext/locale/ext-lang-it.js on lines 185..261
public/ext/locale/ext-lang-ja.js on lines 189..265
public/ext/locale/ext-lang-ko.js on lines 156..232
public/ext/locale/ext-lang-lt.js on lines 198..274
public/ext/locale/ext-lang-nl.js on lines 194..270
public/ext/locale/ext-lang-no_NB.js on lines 185..261
public/ext/locale/ext-lang-no_NN.js on lines 185..261
public/ext/locale/ext-lang-pl.js on lines 195..271
public/ext/locale/ext-lang-pt.js on lines 159..235
public/ext/locale/ext-lang-pt_BR.js on lines 201..277
public/ext/locale/ext-lang-ro.js on lines 185..261
public/ext/locale/ext-lang-ru.js on lines 199..275
public/ext/locale/ext-lang-th.js on lines 185..261
public/ext/locale/ext-lang-tr.js on lines 197..273
public/ext/locale/ext-lang-ukr.js on lines 160..236

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

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

if(Ext.form.HtmlEditor){
  Ext.apply(Ext.form.HtmlEditor.prototype, {
    createLinkText : 'لطفا آدرس لینک را وارد کنید:',
    buttonTips : {
      bold : {
Severity: Major
Found in public/ext/locale/ext-lang-fa.js and 30 other locations - About 1 day to fix
public/ext/locale/ext-lang-bg.js on lines 177..253
public/ext/locale/ext-lang-ca.js on lines 186..262
public/ext/locale/ext-lang-cs.js on lines 184..260
public/ext/locale/ext-lang-de.js on lines 196..272
public/ext/locale/ext-lang-el_GR.js on lines 198..274
public/ext/locale/ext-lang-en.js on lines 194..270
public/ext/locale/ext-lang-en_GB.js on lines 190..266
public/ext/locale/ext-lang-es.js on lines 189..265
public/ext/locale/ext-lang-fi.js on lines 189..265
public/ext/locale/ext-lang-fr.js on lines 211..287
public/ext/locale/ext-lang-he.js on lines 183..259
public/ext/locale/ext-lang-hr.js on lines 186..262
public/ext/locale/ext-lang-hu.js on lines 187..263
public/ext/locale/ext-lang-id.js on lines 193..269
public/ext/locale/ext-lang-it.js on lines 185..261
public/ext/locale/ext-lang-ja.js on lines 189..265
public/ext/locale/ext-lang-ko.js on lines 156..232
public/ext/locale/ext-lang-lt.js on lines 198..274
public/ext/locale/ext-lang-nl.js on lines 194..270
public/ext/locale/ext-lang-no_NB.js on lines 185..261
public/ext/locale/ext-lang-no_NN.js on lines 185..261
public/ext/locale/ext-lang-pl.js on lines 195..271
public/ext/locale/ext-lang-pt.js on lines 159..235
public/ext/locale/ext-lang-pt_BR.js on lines 201..277
public/ext/locale/ext-lang-pt_PT.js on lines 184..260
public/ext/locale/ext-lang-ro.js on lines 185..261
public/ext/locale/ext-lang-ru.js on lines 199..275
public/ext/locale/ext-lang-th.js on lines 185..261
public/ext/locale/ext-lang-tr.js on lines 197..273
public/ext/locale/ext-lang-ukr.js on lines 160..236

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

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

if(Ext.form.HtmlEditor){
  Ext.apply(Ext.form.HtmlEditor.prototype, {
    createLinkText : 'Please enter the URL for the link:',
    buttonTips : {
      bold : {
Severity: Major
Found in public/ext/locale/ext-lang-en_GB.js and 30 other locations - About 1 day to fix
public/ext/locale/ext-lang-bg.js on lines 177..253
public/ext/locale/ext-lang-ca.js on lines 186..262
public/ext/locale/ext-lang-cs.js on lines 184..260
public/ext/locale/ext-lang-de.js on lines 196..272
public/ext/locale/ext-lang-el_GR.js on lines 198..274
public/ext/locale/ext-lang-en.js on lines 194..270
public/ext/locale/ext-lang-es.js on lines 189..265
public/ext/locale/ext-lang-fa.js on lines 171..247
public/ext/locale/ext-lang-fi.js on lines 189..265
public/ext/locale/ext-lang-fr.js on lines 211..287
public/ext/locale/ext-lang-he.js on lines 183..259
public/ext/locale/ext-lang-hr.js on lines 186..262
public/ext/locale/ext-lang-hu.js on lines 187..263
public/ext/locale/ext-lang-id.js on lines 193..269
public/ext/locale/ext-lang-it.js on lines 185..261
public/ext/locale/ext-lang-ja.js on lines 189..265
public/ext/locale/ext-lang-ko.js on lines 156..232
public/ext/locale/ext-lang-lt.js on lines 198..274
public/ext/locale/ext-lang-nl.js on lines 194..270
public/ext/locale/ext-lang-no_NB.js on lines 185..261
public/ext/locale/ext-lang-no_NN.js on lines 185..261
public/ext/locale/ext-lang-pl.js on lines 195..271
public/ext/locale/ext-lang-pt.js on lines 159..235
public/ext/locale/ext-lang-pt_BR.js on lines 201..277
public/ext/locale/ext-lang-pt_PT.js on lines 184..260
public/ext/locale/ext-lang-ro.js on lines 185..261
public/ext/locale/ext-lang-ru.js on lines 199..275
public/ext/locale/ext-lang-th.js on lines 185..261
public/ext/locale/ext-lang-tr.js on lines 197..273
public/ext/locale/ext-lang-ukr.js on lines 160..236

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

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

if(Ext.form.HtmlEditor){
  Ext.apply(Ext.form.HtmlEditor.prototype, {
    createLinkText : 'Inserire un URL per il link:',
    buttonTips : {
      bold : {
Severity: Major
Found in public/ext/locale/ext-lang-it.js and 30 other locations - About 1 day to fix
public/ext/locale/ext-lang-bg.js on lines 177..253
public/ext/locale/ext-lang-ca.js on lines 186..262
public/ext/locale/ext-lang-cs.js on lines 184..260
public/ext/locale/ext-lang-de.js on lines 196..272
public/ext/locale/ext-lang-el_GR.js on lines 198..274
public/ext/locale/ext-lang-en.js on lines 194..270
public/ext/locale/ext-lang-en_GB.js on lines 190..266
public/ext/locale/ext-lang-es.js on lines 189..265
public/ext/locale/ext-lang-fa.js on lines 171..247
public/ext/locale/ext-lang-fi.js on lines 189..265
public/ext/locale/ext-lang-fr.js on lines 211..287
public/ext/locale/ext-lang-he.js on lines 183..259
public/ext/locale/ext-lang-hr.js on lines 186..262
public/ext/locale/ext-lang-hu.js on lines 187..263
public/ext/locale/ext-lang-id.js on lines 193..269
public/ext/locale/ext-lang-ja.js on lines 189..265
public/ext/locale/ext-lang-ko.js on lines 156..232
public/ext/locale/ext-lang-lt.js on lines 198..274
public/ext/locale/ext-lang-nl.js on lines 194..270
public/ext/locale/ext-lang-no_NB.js on lines 185..261
public/ext/locale/ext-lang-no_NN.js on lines 185..261
public/ext/locale/ext-lang-pl.js on lines 195..271
public/ext/locale/ext-lang-pt.js on lines 159..235
public/ext/locale/ext-lang-pt_BR.js on lines 201..277
public/ext/locale/ext-lang-pt_PT.js on lines 184..260
public/ext/locale/ext-lang-ro.js on lines 185..261
public/ext/locale/ext-lang-ru.js on lines 199..275
public/ext/locale/ext-lang-th.js on lines 185..261
public/ext/locale/ext-lang-tr.js on lines 197..273
public/ext/locale/ext-lang-ukr.js on lines 160..236

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

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

if(Ext.form.HtmlEditor){
   Ext.apply(Ext.form.HtmlEditor.prototype, {
     createLinkText : 'Будь-ласка введіть адресу:',
     buttonTips : {
            bold : {
Severity: Major
Found in public/ext/locale/ext-lang-ukr.js and 30 other locations - About 1 day to fix
public/ext/locale/ext-lang-bg.js on lines 177..253
public/ext/locale/ext-lang-ca.js on lines 186..262
public/ext/locale/ext-lang-cs.js on lines 184..260
public/ext/locale/ext-lang-de.js on lines 196..272
public/ext/locale/ext-lang-el_GR.js on lines 198..274
public/ext/locale/ext-lang-en.js on lines 194..270
public/ext/locale/ext-lang-en_GB.js on lines 190..266
public/ext/locale/ext-lang-es.js on lines 189..265
public/ext/locale/ext-lang-fa.js on lines 171..247
public/ext/locale/ext-lang-fi.js on lines 189..265
public/ext/locale/ext-lang-fr.js on lines 211..287
public/ext/locale/ext-lang-he.js on lines 183..259
public/ext/locale/ext-lang-hr.js on lines 186..262
public/ext/locale/ext-lang-hu.js on lines 187..263
public/ext/locale/ext-lang-id.js on lines 193..269
public/ext/locale/ext-lang-it.js on lines 185..261
public/ext/locale/ext-lang-ja.js on lines 189..265
public/ext/locale/ext-lang-ko.js on lines 156..232
public/ext/locale/ext-lang-lt.js on lines 198..274
public/ext/locale/ext-lang-nl.js on lines 194..270
public/ext/locale/ext-lang-no_NB.js on lines 185..261
public/ext/locale/ext-lang-no_NN.js on lines 185..261
public/ext/locale/ext-lang-pl.js on lines 195..271
public/ext/locale/ext-lang-pt.js on lines 159..235
public/ext/locale/ext-lang-pt_BR.js on lines 201..277
public/ext/locale/ext-lang-pt_PT.js on lines 184..260
public/ext/locale/ext-lang-ro.js on lines 185..261
public/ext/locale/ext-lang-ru.js on lines 199..275
public/ext/locale/ext-lang-th.js on lines 185..261
public/ext/locale/ext-lang-tr.js on lines 197..273

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

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

if(Ext.form.HtmlEditor){
  Ext.apply(Ext.form.HtmlEditor.prototype, {
    createLinkText : 'Si us plau, tecleixi la URL per l\'enllaç:',
    buttonTips : {
      bold : {
Severity: Major
Found in public/ext/locale/ext-lang-ca.js and 30 other locations - About 1 day to fix
public/ext/locale/ext-lang-bg.js on lines 177..253
public/ext/locale/ext-lang-cs.js on lines 184..260
public/ext/locale/ext-lang-de.js on lines 196..272
public/ext/locale/ext-lang-el_GR.js on lines 198..274
public/ext/locale/ext-lang-en.js on lines 194..270
public/ext/locale/ext-lang-en_GB.js on lines 190..266
public/ext/locale/ext-lang-es.js on lines 189..265
public/ext/locale/ext-lang-fa.js on lines 171..247
public/ext/locale/ext-lang-fi.js on lines 189..265
public/ext/locale/ext-lang-fr.js on lines 211..287
public/ext/locale/ext-lang-he.js on lines 183..259
public/ext/locale/ext-lang-hr.js on lines 186..262
public/ext/locale/ext-lang-hu.js on lines 187..263
public/ext/locale/ext-lang-id.js on lines 193..269
public/ext/locale/ext-lang-it.js on lines 185..261
public/ext/locale/ext-lang-ja.js on lines 189..265
public/ext/locale/ext-lang-ko.js on lines 156..232
public/ext/locale/ext-lang-lt.js on lines 198..274
public/ext/locale/ext-lang-nl.js on lines 194..270
public/ext/locale/ext-lang-no_NB.js on lines 185..261
public/ext/locale/ext-lang-no_NN.js on lines 185..261
public/ext/locale/ext-lang-pl.js on lines 195..271
public/ext/locale/ext-lang-pt.js on lines 159..235
public/ext/locale/ext-lang-pt_BR.js on lines 201..277
public/ext/locale/ext-lang-pt_PT.js on lines 184..260
public/ext/locale/ext-lang-ro.js on lines 185..261
public/ext/locale/ext-lang-ru.js on lines 199..275
public/ext/locale/ext-lang-th.js on lines 185..261
public/ext/locale/ext-lang-tr.js on lines 197..273
public/ext/locale/ext-lang-ukr.js on lines 160..236

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

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

if(Ext.form.HtmlEditor){
   Ext.apply(Ext.form.HtmlEditor.prototype, {
      createLinkText : "Veuillez entrer l'URL pour ce lien:",
          buttonTips : {
              bold : {
Severity: Major
Found in public/ext/locale/ext-lang-fr.js and 30 other locations - About 1 day to fix
public/ext/locale/ext-lang-bg.js on lines 177..253
public/ext/locale/ext-lang-ca.js on lines 186..262
public/ext/locale/ext-lang-cs.js on lines 184..260
public/ext/locale/ext-lang-de.js on lines 196..272
public/ext/locale/ext-lang-el_GR.js on lines 198..274
public/ext/locale/ext-lang-en.js on lines 194..270
public/ext/locale/ext-lang-en_GB.js on lines 190..266
public/ext/locale/ext-lang-es.js on lines 189..265
public/ext/locale/ext-lang-fa.js on lines 171..247
public/ext/locale/ext-lang-fi.js on lines 189..265
public/ext/locale/ext-lang-he.js on lines 183..259
public/ext/locale/ext-lang-hr.js on lines 186..262
public/ext/locale/ext-lang-hu.js on lines 187..263
public/ext/locale/ext-lang-id.js on lines 193..269
public/ext/locale/ext-lang-it.js on lines 185..261
public/ext/locale/ext-lang-ja.js on lines 189..265
public/ext/locale/ext-lang-ko.js on lines 156..232
public/ext/locale/ext-lang-lt.js on lines 198..274
public/ext/locale/ext-lang-nl.js on lines 194..270
public/ext/locale/ext-lang-no_NB.js on lines 185..261
public/ext/locale/ext-lang-no_NN.js on lines 185..261
public/ext/locale/ext-lang-pl.js on lines 195..271
public/ext/locale/ext-lang-pt.js on lines 159..235
public/ext/locale/ext-lang-pt_BR.js on lines 201..277
public/ext/locale/ext-lang-pt_PT.js on lines 184..260
public/ext/locale/ext-lang-ro.js on lines 185..261
public/ext/locale/ext-lang-ru.js on lines 199..275
public/ext/locale/ext-lang-th.js on lines 185..261
public/ext/locale/ext-lang-tr.js on lines 197..273
public/ext/locale/ext-lang-ukr.js on lines 160..236

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

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

if(Ext.form.HtmlEditor){
   Ext.apply(Ext.form.HtmlEditor.prototype, {
     createLinkText : 'Por favor, entre com o URL do link:',
     buttonTips : {
            bold : {
Severity: Major
Found in public/ext/locale/ext-lang-pt.js and 30 other locations - About 1 day to fix
public/ext/locale/ext-lang-bg.js on lines 177..253
public/ext/locale/ext-lang-ca.js on lines 186..262
public/ext/locale/ext-lang-cs.js on lines 184..260
public/ext/locale/ext-lang-de.js on lines 196..272
public/ext/locale/ext-lang-el_GR.js on lines 198..274
public/ext/locale/ext-lang-en.js on lines 194..270
public/ext/locale/ext-lang-en_GB.js on lines 190..266
public/ext/locale/ext-lang-es.js on lines 189..265
public/ext/locale/ext-lang-fa.js on lines 171..247
public/ext/locale/ext-lang-fi.js on lines 189..265
public/ext/locale/ext-lang-fr.js on lines 211..287
public/ext/locale/ext-lang-he.js on lines 183..259
public/ext/locale/ext-lang-hr.js on lines 186..262
public/ext/locale/ext-lang-hu.js on lines 187..263
public/ext/locale/ext-lang-id.js on lines 193..269
public/ext/locale/ext-lang-it.js on lines 185..261
public/ext/locale/ext-lang-ja.js on lines 189..265
public/ext/locale/ext-lang-ko.js on lines 156..232
public/ext/locale/ext-lang-lt.js on lines 198..274
public/ext/locale/ext-lang-nl.js on lines 194..270
public/ext/locale/ext-lang-no_NB.js on lines 185..261
public/ext/locale/ext-lang-no_NN.js on lines 185..261
public/ext/locale/ext-lang-pl.js on lines 195..271
public/ext/locale/ext-lang-pt_BR.js on lines 201..277
public/ext/locale/ext-lang-pt_PT.js on lines 184..260
public/ext/locale/ext-lang-ro.js on lines 185..261
public/ext/locale/ext-lang-ru.js on lines 199..275
public/ext/locale/ext-lang-th.js on lines 185..261
public/ext/locale/ext-lang-tr.js on lines 197..273
public/ext/locale/ext-lang-ukr.js on lines 160..236

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

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 save_physically has a Cognitive Complexity of 47 (exceeds 5 allowed). Consider refactoring.
Open

  def save_physically
    return false if !valid?
    is_new = new_record?

    if is_new
Severity: Minor
Found in app/models/virtual_server.rb - 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

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

function owp_TerminateAccount($params) 
{
    $username = $params["username"];
    $result = _owp_apiCall('users/get_by_login', array('login' => $username));
    $userId = (int)$result->id;
Severity: Major
Found in utils/whmcs/owp/owp.php and 2 other locations - About 5 hrs to fix
utils/whmcs/owp/owp.php on lines 151..174
utils/whmcs/owp/owp.php on lines 176..199

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

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

function owp_UnsuspendAccount($params) 
{
    $username = $params["username"];
    $result = _owp_apiCall('users/get_by_login', array('login' => $username));
    $userId = (int)$result->id;
Severity: Major
Found in utils/whmcs/owp/owp.php and 2 other locations - About 5 hrs to fix
utils/whmcs/owp/owp.php on lines 126..149
utils/whmcs/owp/owp.php on lines 151..174

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

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

function owp_SuspendAccount($params) 
{
    $username = $params["username"];
    $result = _owp_apiCall('users/get_by_login', array('login' => $username));
    $userId = (int)$result->id;
Severity: Major
Found in utils/whmcs/owp/owp.php and 2 other locations - About 5 hrs to fix
utils/whmcs/owp/owp.php on lines 126..149
utils/whmcs/owp/owp.php on lines 176..199

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

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 new has a Cognitive Complexity of 32 (exceeds 5 allowed). Consider refactoring.
Open

  def new
    @available_locales = I18n.available_locales.map {
      |locale| [locale.to_s, I18n.t('language.title', :locale => locale) + " (#{locale})"]
    }.sort

Severity: Minor
Found in app/controllers/sessions_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

File watchdog.rb has 338 lines of code (exceeds 250 allowed). Consider refactoring.
Open

require 'drb/drb'
require 'date'
require 'ostruct'

CURRENT_DIR = File.expand_path(File.dirname(__FILE__)) + '/'
Severity: Minor
Found in utils/watchdog/watchdog.rb - About 4 hrs to fix

    File virtual_server.rb has 337 lines of code (exceeds 250 allowed). Consider refactoring.
    Open

    class VirtualServer < ActiveRecord::Base
      attr_accessible :identity, :ip_address, :host_name, :hardware_server_id,
        :orig_os_template, :password, :start_on_boot, :start_after_creation, :state,
        :nameserver, :search_domain, :diskspace, :memory, :password_confirmation,
        :user_id, :orig_server_template, :description, :cpu_units, :cpus, :cpu_limit,
    Severity: Minor
    Found in app/models/virtual_server.rb - About 4 hrs to fix

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

        def save_physically
          return false if !valid?
      
          content = ""
          content << 'ONBOOT="' + (start_on_boot ? "yes" : "no") + '"' + "\n"
      Severity: Minor
      Found in app/models/server_template.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

      Class VirtualServer has 32 methods (exceeds 20 allowed). Consider refactoring.
      Open

      class VirtualServer < ActiveRecord::Base
        attr_accessible :identity, :ip_address, :host_name, :hardware_server_id,
          :orig_os_template, :password, :start_on_boot, :start_after_creation, :state,
          :nameserver, :search_domain, :diskspace, :memory, :password_confirmation,
          :user_id, :orig_server_template, :description, :cpu_units, :cpus, :cpu_limit,
      Severity: Minor
      Found in app/models/virtual_server.rb - About 4 hrs to fix
        Severity
        Category
        Status
        Source
        Language