resource-watch/query

View on GitHub

Showing 47 of 65 total issues

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

    cf_terraialertsbyisoandregion: {
        uri: '/terrai-alerts/admin/${iso}/${id1}',
        method: 'GET',
        arguments: [{
            name: 'iso',
Severity: Major
Found in app/src/services/endpoints.js and 9 other locations - About 2 hrs to fix
app/src/services/endpoints.js on lines 20..40
app/src/services/endpoints.js on lines 58..78
app/src/services/endpoints.js on lines 122..142
app/src/services/endpoints.js on lines 160..180
app/src/services/endpoints.js on lines 224..244
app/src/services/endpoints.js on lines 262..282
app/src/services/endpoints.js on lines 468..488
app/src/services/endpoints.js on lines 506..526
app/src/services/endpoints.js on lines 750..770

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

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

    cf_guiralossbyisoandregion: {
        uri: '/guira-loss/admin/${iso}/${id1}',
        method: 'GET',
        arguments: [{
            name: 'iso',
Severity: Major
Found in app/src/services/endpoints.js and 9 other locations - About 2 hrs to fix
app/src/services/endpoints.js on lines 20..40
app/src/services/endpoints.js on lines 58..78
app/src/services/endpoints.js on lines 122..142
app/src/services/endpoints.js on lines 160..180
app/src/services/endpoints.js on lines 262..282
app/src/services/endpoints.js on lines 468..488
app/src/services/endpoints.js on lines 506..526
app/src/services/endpoints.js on lines 712..732
app/src/services/endpoints.js on lines 750..770

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

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

    cf_umdlossgainbyiso: {
        uri: '/terrai-alerts/admin/${iso}',
        method: 'GET',
        arguments: [{
            name: 'iso',
Severity: Major
Found in app/src/services/endpoints.js and 2 other locations - About 2 hrs to fix
app/src/services/endpoints.js on lines 843..863
app/src/services/endpoints.js on lines 889..909

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

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

    cf_umdlossgainbywdpa: {
        uri: '/terrai-alerts/wdpa/${id}',
        method: 'GET',
        arguments: [{
            name: 'id',
Severity: Major
Found in app/src/services/endpoints.js and 2 other locations - About 2 hrs to fix
app/src/services/endpoints.js on lines 797..817
app/src/services/endpoints.js on lines 889..909

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

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

    cf_umdlossgainbygeostore: {
        uri: '/terrai-alerts',
        method: 'GET',
        arguments: [{
            name: 'geostore',
Severity: Major
Found in app/src/services/endpoints.js and 2 other locations - About 2 hrs to fix
app/src/services/endpoints.js on lines 797..817
app/src/services/endpoints.js on lines 843..863

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

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

    cf_guiralossbywdpa: {
        uri: '/guira-loss/wdpa/${id}',
        method: 'GET',
        arguments: [{
            name: 'id',
Severity: Major
Found in app/src/services/endpoints.js and 14 other locations - About 1 hr to fix
app/src/services/endpoints.js on lines 3..19
app/src/services/endpoints.js on lines 41..57
app/src/services/endpoints.js on lines 79..95
app/src/services/endpoints.js on lines 105..121
app/src/services/endpoints.js on lines 143..159
app/src/services/endpoints.js on lines 181..197
app/src/services/endpoints.js on lines 207..223
app/src/services/endpoints.js on lines 283..299
app/src/services/endpoints.js on lines 451..467
app/src/services/endpoints.js on lines 489..505
app/src/services/endpoints.js on lines 527..543
app/src/services/endpoints.js on lines 695..711
app/src/services/endpoints.js on lines 733..749
app/src/services/endpoints.js on lines 771..787

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

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

    cf_terraialertsbyiso: {
        uri: '/terrai-alerts/admin/${iso}',
        method: 'GET',
        arguments: [{
            name: 'iso',
Severity: Major
Found in app/src/services/endpoints.js and 14 other locations - About 1 hr to fix
app/src/services/endpoints.js on lines 3..19
app/src/services/endpoints.js on lines 41..57
app/src/services/endpoints.js on lines 79..95
app/src/services/endpoints.js on lines 105..121
app/src/services/endpoints.js on lines 143..159
app/src/services/endpoints.js on lines 181..197
app/src/services/endpoints.js on lines 207..223
app/src/services/endpoints.js on lines 245..261
app/src/services/endpoints.js on lines 283..299
app/src/services/endpoints.js on lines 451..467
app/src/services/endpoints.js on lines 489..505
app/src/services/endpoints.js on lines 527..543
app/src/services/endpoints.js on lines 733..749
app/src/services/endpoints.js on lines 771..787

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

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

    cf_gladalertsbyiso: {
        uri: '/glad-alerts/admin/${iso}',
        method: 'GET',
        arguments: [{
            name: 'iso',
Severity: Major
Found in app/src/services/endpoints.js and 14 other locations - About 1 hr to fix
app/src/services/endpoints.js on lines 3..19
app/src/services/endpoints.js on lines 41..57
app/src/services/endpoints.js on lines 79..95
app/src/services/endpoints.js on lines 143..159
app/src/services/endpoints.js on lines 181..197
app/src/services/endpoints.js on lines 207..223
app/src/services/endpoints.js on lines 245..261
app/src/services/endpoints.js on lines 283..299
app/src/services/endpoints.js on lines 451..467
app/src/services/endpoints.js on lines 489..505
app/src/services/endpoints.js on lines 527..543
app/src/services/endpoints.js on lines 695..711
app/src/services/endpoints.js on lines 733..749
app/src/services/endpoints.js on lines 771..787

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

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

    cf_prodeslossbywdpa: {
        uri: '/prodes-loss/wdpa/${id}',
        method: 'GET',
        arguments: [{
            name: 'id',
Severity: Major
Found in app/src/services/endpoints.js and 14 other locations - About 1 hr to fix
app/src/services/endpoints.js on lines 3..19
app/src/services/endpoints.js on lines 41..57
app/src/services/endpoints.js on lines 79..95
app/src/services/endpoints.js on lines 105..121
app/src/services/endpoints.js on lines 143..159
app/src/services/endpoints.js on lines 181..197
app/src/services/endpoints.js on lines 207..223
app/src/services/endpoints.js on lines 245..261
app/src/services/endpoints.js on lines 283..299
app/src/services/endpoints.js on lines 451..467
app/src/services/endpoints.js on lines 527..543
app/src/services/endpoints.js on lines 695..711
app/src/services/endpoints.js on lines 733..749
app/src/services/endpoints.js on lines 771..787

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

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

    cf_guiralossbygeostore: {
        uri: '/guira-loss',
        method: 'GET',
        arguments: [{
            name: 'geostore',
Severity: Major
Found in app/src/services/endpoints.js and 14 other locations - About 1 hr to fix
app/src/services/endpoints.js on lines 3..19
app/src/services/endpoints.js on lines 41..57
app/src/services/endpoints.js on lines 79..95
app/src/services/endpoints.js on lines 105..121
app/src/services/endpoints.js on lines 143..159
app/src/services/endpoints.js on lines 181..197
app/src/services/endpoints.js on lines 207..223
app/src/services/endpoints.js on lines 245..261
app/src/services/endpoints.js on lines 451..467
app/src/services/endpoints.js on lines 489..505
app/src/services/endpoints.js on lines 527..543
app/src/services/endpoints.js on lines 695..711
app/src/services/endpoints.js on lines 733..749
app/src/services/endpoints.js on lines 771..787

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

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

    cf_prodeslossbygeostore: {
        uri: '/prodes-loss',
        method: 'GET',
        arguments: [{
            name: 'geostore',
Severity: Major
Found in app/src/services/endpoints.js and 14 other locations - About 1 hr to fix
app/src/services/endpoints.js on lines 3..19
app/src/services/endpoints.js on lines 41..57
app/src/services/endpoints.js on lines 79..95
app/src/services/endpoints.js on lines 105..121
app/src/services/endpoints.js on lines 143..159
app/src/services/endpoints.js on lines 181..197
app/src/services/endpoints.js on lines 207..223
app/src/services/endpoints.js on lines 245..261
app/src/services/endpoints.js on lines 283..299
app/src/services/endpoints.js on lines 451..467
app/src/services/endpoints.js on lines 489..505
app/src/services/endpoints.js on lines 695..711
app/src/services/endpoints.js on lines 733..749
app/src/services/endpoints.js on lines 771..787

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

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

    cf_prodeslossbyiso: {
        uri: '/prodes-loss/admin/${iso}',
        method: 'GET',
        arguments: [{
            name: 'iso',
Severity: Major
Found in app/src/services/endpoints.js and 14 other locations - About 1 hr to fix
app/src/services/endpoints.js on lines 3..19
app/src/services/endpoints.js on lines 41..57
app/src/services/endpoints.js on lines 79..95
app/src/services/endpoints.js on lines 105..121
app/src/services/endpoints.js on lines 143..159
app/src/services/endpoints.js on lines 181..197
app/src/services/endpoints.js on lines 207..223
app/src/services/endpoints.js on lines 245..261
app/src/services/endpoints.js on lines 283..299
app/src/services/endpoints.js on lines 489..505
app/src/services/endpoints.js on lines 527..543
app/src/services/endpoints.js on lines 695..711
app/src/services/endpoints.js on lines 733..749
app/src/services/endpoints.js on lines 771..787

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

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

    cf_terraialertsbywdpa: {
        uri: '/terrai-alerts/wdpa/${id}',
        method: 'GET',
        arguments: [{
            name: 'id',
Severity: Major
Found in app/src/services/endpoints.js and 14 other locations - About 1 hr to fix
app/src/services/endpoints.js on lines 3..19
app/src/services/endpoints.js on lines 41..57
app/src/services/endpoints.js on lines 79..95
app/src/services/endpoints.js on lines 105..121
app/src/services/endpoints.js on lines 143..159
app/src/services/endpoints.js on lines 181..197
app/src/services/endpoints.js on lines 207..223
app/src/services/endpoints.js on lines 245..261
app/src/services/endpoints.js on lines 283..299
app/src/services/endpoints.js on lines 451..467
app/src/services/endpoints.js on lines 489..505
app/src/services/endpoints.js on lines 527..543
app/src/services/endpoints.js on lines 695..711
app/src/services/endpoints.js on lines 771..787

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

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

    cf_viirsfiresbywdpa: {
        uri: '/viirs-active-fires/wdpa/${id}',
        method: 'GET',
        arguments: [{
            name: 'id',
Severity: Major
Found in app/src/services/endpoints.js and 14 other locations - About 1 hr to fix
app/src/services/endpoints.js on lines 3..19
app/src/services/endpoints.js on lines 79..95
app/src/services/endpoints.js on lines 105..121
app/src/services/endpoints.js on lines 143..159
app/src/services/endpoints.js on lines 181..197
app/src/services/endpoints.js on lines 207..223
app/src/services/endpoints.js on lines 245..261
app/src/services/endpoints.js on lines 283..299
app/src/services/endpoints.js on lines 451..467
app/src/services/endpoints.js on lines 489..505
app/src/services/endpoints.js on lines 527..543
app/src/services/endpoints.js on lines 695..711
app/src/services/endpoints.js on lines 733..749
app/src/services/endpoints.js on lines 771..787

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

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

    cf_guiralossbyiso: {
        uri: '/guira-loss/admin/${iso}',
        method: 'GET',
        arguments: [{
            name: 'iso',
Severity: Major
Found in app/src/services/endpoints.js and 14 other locations - About 1 hr to fix
app/src/services/endpoints.js on lines 3..19
app/src/services/endpoints.js on lines 41..57
app/src/services/endpoints.js on lines 79..95
app/src/services/endpoints.js on lines 105..121
app/src/services/endpoints.js on lines 143..159
app/src/services/endpoints.js on lines 181..197
app/src/services/endpoints.js on lines 245..261
app/src/services/endpoints.js on lines 283..299
app/src/services/endpoints.js on lines 451..467
app/src/services/endpoints.js on lines 489..505
app/src/services/endpoints.js on lines 527..543
app/src/services/endpoints.js on lines 695..711
app/src/services/endpoints.js on lines 733..749
app/src/services/endpoints.js on lines 771..787

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

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

    cf_viirsfiresbyiso: {
        uri: '/viirs-active-fires/admin/${iso}',
        method: 'GET',
        arguments: [{
            name: 'iso',
Severity: Major
Found in app/src/services/endpoints.js and 14 other locations - About 1 hr to fix
app/src/services/endpoints.js on lines 41..57
app/src/services/endpoints.js on lines 79..95
app/src/services/endpoints.js on lines 105..121
app/src/services/endpoints.js on lines 143..159
app/src/services/endpoints.js on lines 181..197
app/src/services/endpoints.js on lines 207..223
app/src/services/endpoints.js on lines 245..261
app/src/services/endpoints.js on lines 283..299
app/src/services/endpoints.js on lines 451..467
app/src/services/endpoints.js on lines 489..505
app/src/services/endpoints.js on lines 527..543
app/src/services/endpoints.js on lines 695..711
app/src/services/endpoints.js on lines 733..749
app/src/services/endpoints.js on lines 771..787

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

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

    cf_viirsfiresbygeostore: {
        uri: '/viirs-active-fires',
        method: 'GET',
        arguments: [{
            name: 'geostore',
Severity: Major
Found in app/src/services/endpoints.js and 14 other locations - About 1 hr to fix
app/src/services/endpoints.js on lines 3..19
app/src/services/endpoints.js on lines 41..57
app/src/services/endpoints.js on lines 105..121
app/src/services/endpoints.js on lines 143..159
app/src/services/endpoints.js on lines 181..197
app/src/services/endpoints.js on lines 207..223
app/src/services/endpoints.js on lines 245..261
app/src/services/endpoints.js on lines 283..299
app/src/services/endpoints.js on lines 451..467
app/src/services/endpoints.js on lines 489..505
app/src/services/endpoints.js on lines 527..543
app/src/services/endpoints.js on lines 695..711
app/src/services/endpoints.js on lines 733..749
app/src/services/endpoints.js on lines 771..787

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

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

    cf_terraialertsbygeostore: {
        uri: '/terrai-alerts',
        method: 'GET',
        arguments: [{
            name: 'geostore',
Severity: Major
Found in app/src/services/endpoints.js and 14 other locations - About 1 hr to fix
app/src/services/endpoints.js on lines 3..19
app/src/services/endpoints.js on lines 41..57
app/src/services/endpoints.js on lines 79..95
app/src/services/endpoints.js on lines 105..121
app/src/services/endpoints.js on lines 143..159
app/src/services/endpoints.js on lines 181..197
app/src/services/endpoints.js on lines 207..223
app/src/services/endpoints.js on lines 245..261
app/src/services/endpoints.js on lines 283..299
app/src/services/endpoints.js on lines 451..467
app/src/services/endpoints.js on lines 489..505
app/src/services/endpoints.js on lines 527..543
app/src/services/endpoints.js on lines 695..711
app/src/services/endpoints.js on lines 733..749

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

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

    cf_gladalertsbywdpa: {
        uri: '/glad-alerts/wdpa/${id}',
        method: 'GET',
        arguments: [{
            name: 'id',
Severity: Major
Found in app/src/services/endpoints.js and 14 other locations - About 1 hr to fix
app/src/services/endpoints.js on lines 3..19
app/src/services/endpoints.js on lines 41..57
app/src/services/endpoints.js on lines 79..95
app/src/services/endpoints.js on lines 105..121
app/src/services/endpoints.js on lines 181..197
app/src/services/endpoints.js on lines 207..223
app/src/services/endpoints.js on lines 245..261
app/src/services/endpoints.js on lines 283..299
app/src/services/endpoints.js on lines 451..467
app/src/services/endpoints.js on lines 489..505
app/src/services/endpoints.js on lines 527..543
app/src/services/endpoints.js on lines 695..711
app/src/services/endpoints.js on lines 733..749
app/src/services/endpoints.js on lines 771..787

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

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

    cf_gladalertsbygeostore: {
        uri: '/glad-alerts',
        method: 'GET',
        arguments: [{
            name: 'geostore',
Severity: Major
Found in app/src/services/endpoints.js and 14 other locations - About 1 hr to fix
app/src/services/endpoints.js on lines 3..19
app/src/services/endpoints.js on lines 41..57
app/src/services/endpoints.js on lines 79..95
app/src/services/endpoints.js on lines 105..121
app/src/services/endpoints.js on lines 143..159
app/src/services/endpoints.js on lines 207..223
app/src/services/endpoints.js on lines 245..261
app/src/services/endpoints.js on lines 283..299
app/src/services/endpoints.js on lines 451..467
app/src/services/endpoints.js on lines 489..505
app/src/services/endpoints.js on lines 527..543
app/src/services/endpoints.js on lines 695..711
app/src/services/endpoints.js on lines 733..749
app/src/services/endpoints.js on lines 771..787

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

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