datacite/bracco

View on GitHub

Showing 695 of 898 total issues

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

    {
      reference: './Beerware.html',
      isDeprecatedLicenseId: false,
      detailsUrl: 'http://spdx.org/licenses/Beerware.json',
      referenceNumber: '243',
Severity: Major
Found in app/spdx.js and 29 other locations - About 30 mins to fix
app/spdx.js on lines 552..564
app/spdx.js on lines 1044..1056
app/spdx.js on lines 1372..1384
app/spdx.js on lines 1441..1453
app/spdx.js on lines 1567..1579
app/spdx.js on lines 2441..2453
app/spdx.js on lines 2474..2486
app/spdx.js on lines 2487..2499
app/spdx.js on lines 2500..2512
app/spdx.js on lines 2560..2572
app/spdx.js on lines 2615..2627
app/spdx.js on lines 2656..2668
app/spdx.js on lines 2739..2751
app/spdx.js on lines 2772..2784
app/spdx.js on lines 2998..3010
app/spdx.js on lines 3083..3095
app/spdx.js on lines 3096..3108
app/spdx.js on lines 3155..3167
app/spdx.js on lines 3370..3382
app/spdx.js on lines 3383..3395
app/spdx.js on lines 3480..3492
app/spdx.js on lines 3536..3548
app/spdx.js on lines 3638..3650
app/spdx.js on lines 3869..3881
app/spdx.js on lines 3882..3894
app/spdx.js on lines 3983..3995
app/spdx.js on lines 4392..4404
app/spdx.js on lines 4490..4502
app/spdx.js on lines 4503..4515

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

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

    {
      reference: './LiLiQ-Rplus-1.1.html',
      isDeprecatedLicenseId: false,
      detailsUrl: 'http://spdx.org/licenses/LiLiQ-Rplus-1.1.json',
      referenceNumber: '335',
Severity: Major
Found in app/spdx.js and 29 other locations - About 30 mins to fix
app/spdx.js on lines 552..564
app/spdx.js on lines 644..656
app/spdx.js on lines 1044..1056
app/spdx.js on lines 1372..1384
app/spdx.js on lines 1441..1453
app/spdx.js on lines 1567..1579
app/spdx.js on lines 2441..2453
app/spdx.js on lines 2474..2486
app/spdx.js on lines 2487..2499
app/spdx.js on lines 2560..2572
app/spdx.js on lines 2615..2627
app/spdx.js on lines 2656..2668
app/spdx.js on lines 2739..2751
app/spdx.js on lines 2772..2784
app/spdx.js on lines 2998..3010
app/spdx.js on lines 3083..3095
app/spdx.js on lines 3096..3108
app/spdx.js on lines 3155..3167
app/spdx.js on lines 3370..3382
app/spdx.js on lines 3383..3395
app/spdx.js on lines 3480..3492
app/spdx.js on lines 3536..3548
app/spdx.js on lines 3638..3650
app/spdx.js on lines 3869..3881
app/spdx.js on lines 3882..3894
app/spdx.js on lines 3983..3995
app/spdx.js on lines 4392..4404
app/spdx.js on lines 4490..4502
app/spdx.js on lines 4503..4515

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

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

    {
      reference: './RSCPL.html',
      isDeprecatedLicenseId: false,
      detailsUrl: 'http://spdx.org/licenses/RSCPL.json',
      referenceNumber: '339',
Severity: Major
Found in app/spdx.js and 29 other locations - About 30 mins to fix
app/spdx.js on lines 552..564
app/spdx.js on lines 644..656
app/spdx.js on lines 1044..1056
app/spdx.js on lines 1372..1384
app/spdx.js on lines 1441..1453
app/spdx.js on lines 1567..1579
app/spdx.js on lines 2441..2453
app/spdx.js on lines 2474..2486
app/spdx.js on lines 2487..2499
app/spdx.js on lines 2500..2512
app/spdx.js on lines 2560..2572
app/spdx.js on lines 2615..2627
app/spdx.js on lines 2656..2668
app/spdx.js on lines 2739..2751
app/spdx.js on lines 2772..2784
app/spdx.js on lines 2998..3010
app/spdx.js on lines 3083..3095
app/spdx.js on lines 3096..3108
app/spdx.js on lines 3155..3167
app/spdx.js on lines 3370..3382
app/spdx.js on lines 3383..3395
app/spdx.js on lines 3480..3492
app/spdx.js on lines 3536..3548
app/spdx.js on lines 3869..3881
app/spdx.js on lines 3882..3894
app/spdx.js on lines 3983..3995
app/spdx.js on lines 4392..4404
app/spdx.js on lines 4490..4502
app/spdx.js on lines 4503..4515

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

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

    {
      reference: './Sendmail-8.23.html',
      isDeprecatedLicenseId: false,
      detailsUrl: 'http://spdx.org/licenses/Sendmail-8.23.json',
      referenceNumber: '176',
Severity: Major
Found in app/spdx.js and 29 other locations - About 30 mins to fix
app/spdx.js on lines 552..564
app/spdx.js on lines 644..656
app/spdx.js on lines 1044..1056
app/spdx.js on lines 1372..1384
app/spdx.js on lines 1441..1453
app/spdx.js on lines 1567..1579
app/spdx.js on lines 2441..2453
app/spdx.js on lines 2474..2486
app/spdx.js on lines 2487..2499
app/spdx.js on lines 2500..2512
app/spdx.js on lines 2560..2572
app/spdx.js on lines 2615..2627
app/spdx.js on lines 2656..2668
app/spdx.js on lines 2739..2751
app/spdx.js on lines 2772..2784
app/spdx.js on lines 2998..3010
app/spdx.js on lines 3083..3095
app/spdx.js on lines 3096..3108
app/spdx.js on lines 3155..3167
app/spdx.js on lines 3370..3382
app/spdx.js on lines 3383..3395
app/spdx.js on lines 3480..3492
app/spdx.js on lines 3536..3548
app/spdx.js on lines 3638..3650
app/spdx.js on lines 3869..3881
app/spdx.js on lines 3983..3995
app/spdx.js on lines 4392..4404
app/spdx.js on lines 4490..4502
app/spdx.js on lines 4503..4515

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

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

    {
      reference: './OPL-1.0.html',
      isDeprecatedLicenseId: false,
      detailsUrl: 'http://spdx.org/licenses/OPL-1.0.json',
      referenceNumber: '338',
Severity: Major
Found in app/spdx.js and 29 other locations - About 30 mins to fix
app/spdx.js on lines 552..564
app/spdx.js on lines 644..656
app/spdx.js on lines 1044..1056
app/spdx.js on lines 1372..1384
app/spdx.js on lines 1441..1453
app/spdx.js on lines 1567..1579
app/spdx.js on lines 2441..2453
app/spdx.js on lines 2474..2486
app/spdx.js on lines 2487..2499
app/spdx.js on lines 2500..2512
app/spdx.js on lines 2560..2572
app/spdx.js on lines 2615..2627
app/spdx.js on lines 2656..2668
app/spdx.js on lines 2739..2751
app/spdx.js on lines 2772..2784
app/spdx.js on lines 2998..3010
app/spdx.js on lines 3083..3095
app/spdx.js on lines 3096..3108
app/spdx.js on lines 3155..3167
app/spdx.js on lines 3383..3395
app/spdx.js on lines 3480..3492
app/spdx.js on lines 3536..3548
app/spdx.js on lines 3638..3650
app/spdx.js on lines 3869..3881
app/spdx.js on lines 3882..3894
app/spdx.js on lines 3983..3995
app/spdx.js on lines 4392..4404
app/spdx.js on lines 4490..4502
app/spdx.js on lines 4503..4515

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

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

    {
      reference: './Sendmail.html',
      isDeprecatedLicenseId: false,
      detailsUrl: 'http://spdx.org/licenses/Sendmail.json',
      referenceNumber: '293',
Severity: Major
Found in app/spdx.js and 29 other locations - About 30 mins to fix
app/spdx.js on lines 552..564
app/spdx.js on lines 644..656
app/spdx.js on lines 1044..1056
app/spdx.js on lines 1372..1384
app/spdx.js on lines 1441..1453
app/spdx.js on lines 1567..1579
app/spdx.js on lines 2441..2453
app/spdx.js on lines 2474..2486
app/spdx.js on lines 2487..2499
app/spdx.js on lines 2500..2512
app/spdx.js on lines 2560..2572
app/spdx.js on lines 2615..2627
app/spdx.js on lines 2656..2668
app/spdx.js on lines 2739..2751
app/spdx.js on lines 2772..2784
app/spdx.js on lines 2998..3010
app/spdx.js on lines 3083..3095
app/spdx.js on lines 3096..3108
app/spdx.js on lines 3155..3167
app/spdx.js on lines 3370..3382
app/spdx.js on lines 3383..3395
app/spdx.js on lines 3480..3492
app/spdx.js on lines 3536..3548
app/spdx.js on lines 3638..3650
app/spdx.js on lines 3882..3894
app/spdx.js on lines 3983..3995
app/spdx.js on lines 4392..4404
app/spdx.js on lines 4490..4502
app/spdx.js on lines 4503..4515

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

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

    {
      reference: './TCL.html',
      isDeprecatedLicenseId: false,
      detailsUrl: 'http://spdx.org/licenses/TCL.json',
      referenceNumber: '54',
Severity: Major
Found in app/spdx.js and 29 other locations - About 30 mins to fix
app/spdx.js on lines 552..564
app/spdx.js on lines 644..656
app/spdx.js on lines 1044..1056
app/spdx.js on lines 1372..1384
app/spdx.js on lines 1441..1453
app/spdx.js on lines 1567..1579
app/spdx.js on lines 2441..2453
app/spdx.js on lines 2474..2486
app/spdx.js on lines 2487..2499
app/spdx.js on lines 2500..2512
app/spdx.js on lines 2560..2572
app/spdx.js on lines 2615..2627
app/spdx.js on lines 2656..2668
app/spdx.js on lines 2739..2751
app/spdx.js on lines 2772..2784
app/spdx.js on lines 2998..3010
app/spdx.js on lines 3083..3095
app/spdx.js on lines 3096..3108
app/spdx.js on lines 3155..3167
app/spdx.js on lines 3370..3382
app/spdx.js on lines 3383..3395
app/spdx.js on lines 3480..3492
app/spdx.js on lines 3536..3548
app/spdx.js on lines 3638..3650
app/spdx.js on lines 3869..3881
app/spdx.js on lines 3882..3894
app/spdx.js on lines 4392..4404
app/spdx.js on lines 4490..4502
app/spdx.js on lines 4503..4515

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

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

    {
      reference: './PostgreSQL.html',
      isDeprecatedLicenseId: false,
      detailsUrl: 'http://spdx.org/licenses/PostgreSQL.json',
      referenceNumber: '11',
Severity: Major
Found in app/spdx.js and 29 other locations - About 30 mins to fix
app/spdx.js on lines 552..564
app/spdx.js on lines 644..656
app/spdx.js on lines 1044..1056
app/spdx.js on lines 1372..1384
app/spdx.js on lines 1441..1453
app/spdx.js on lines 1567..1579
app/spdx.js on lines 2441..2453
app/spdx.js on lines 2474..2486
app/spdx.js on lines 2487..2499
app/spdx.js on lines 2500..2512
app/spdx.js on lines 2560..2572
app/spdx.js on lines 2615..2627
app/spdx.js on lines 2656..2668
app/spdx.js on lines 2739..2751
app/spdx.js on lines 2772..2784
app/spdx.js on lines 2998..3010
app/spdx.js on lines 3083..3095
app/spdx.js on lines 3096..3108
app/spdx.js on lines 3155..3167
app/spdx.js on lines 3370..3382
app/spdx.js on lines 3383..3395
app/spdx.js on lines 3480..3492
app/spdx.js on lines 3638..3650
app/spdx.js on lines 3869..3881
app/spdx.js on lines 3882..3894
app/spdx.js on lines 3983..3995
app/spdx.js on lines 4392..4404
app/spdx.js on lines 4490..4502
app/spdx.js on lines 4503..4515

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

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

  setEvent(state) {
    if (state === 'registered') {
      return 'register';
    } else if (state === 'findable') {
      return 'publish';
Severity: Minor
Found in app/controllers/repositories/show/dois/upload.js and 1 other location - About 30 mins to fix
app/controllers/repositories/show/dois/new.js on lines 12..20

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

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

    {
      reference: './OSET-PL-2.1.html',
      isDeprecatedLicenseId: false,
      detailsUrl: 'http://spdx.org/licenses/OSET-PL-2.1.json',
      referenceNumber: '203',
Severity: Major
Found in app/spdx.js and 29 other locations - About 30 mins to fix
app/spdx.js on lines 552..564
app/spdx.js on lines 644..656
app/spdx.js on lines 1044..1056
app/spdx.js on lines 1372..1384
app/spdx.js on lines 1441..1453
app/spdx.js on lines 1567..1579
app/spdx.js on lines 2441..2453
app/spdx.js on lines 2474..2486
app/spdx.js on lines 2487..2499
app/spdx.js on lines 2500..2512
app/spdx.js on lines 2560..2572
app/spdx.js on lines 2615..2627
app/spdx.js on lines 2656..2668
app/spdx.js on lines 2739..2751
app/spdx.js on lines 2772..2784
app/spdx.js on lines 2998..3010
app/spdx.js on lines 3083..3095
app/spdx.js on lines 3096..3108
app/spdx.js on lines 3155..3167
app/spdx.js on lines 3370..3382
app/spdx.js on lines 3480..3492
app/spdx.js on lines 3536..3548
app/spdx.js on lines 3638..3650
app/spdx.js on lines 3869..3881
app/spdx.js on lines 3882..3894
app/spdx.js on lines 3983..3995
app/spdx.js on lines 4392..4404
app/spdx.js on lines 4490..4502
app/spdx.js on lines 4503..4515

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

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

  if (counter >= 1e9 && counter < 1e12) {
    return `${+(counter / 1e9).toFixed(1)}B`;
  }
Severity: Minor
Found in app/helpers/format-numbers.js and 2 other locations - About 30 mins to fix
app/helpers/format-numbers.js on lines 7..9
app/helpers/format-numbers.js on lines 10..12

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

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

  if (counter >= 1e6 && counter < 1e9) {
    return `${+(counter / 1e6).toFixed(1)}M`;
  }
Severity: Minor
Found in app/helpers/format-numbers.js and 2 other locations - About 30 mins to fix
app/helpers/format-numbers.js on lines 7..9
app/helpers/format-numbers.js on lines 13..15

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

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

export default Fragment.extend(Validations, {
  alternateIdentifier: attr('string', { defaultValue: null }),
  alternateIdentifierType: attr('string', { defaultValue: null })
});
Severity: Minor
Found in app/models/alternate-identifier.js and 1 other location - About 30 mins to fix
app/models/geo-location-point.js on lines 46..49

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

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

export default Fragment.extend(Validations, {
  pointLongitude: attr('number', { defaultValue: null }),
  pointLatitude: attr('number', { defaultValue: null })
});
Severity: Minor
Found in app/models/geo-location-point.js and 1 other location - About 30 mins to fix
app/models/alternate-identifier.js on lines 19..22

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

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

  if (counter >= 1e3 && counter < 1e6) {
    return `${+(counter / 1e3).toFixed(1)}K`;
  }
Severity: Minor
Found in app/helpers/format-numbers.js and 2 other locations - About 30 mins to fix
app/helpers/format-numbers.js on lines 10..12
app/helpers/format-numbers.js on lines 13..15

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

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