SpeciesFileGroup/taxonworks

View on GitHub

Showing 1,085 of 12,579 total issues

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

const MutationFunctions = {
  [MutationNames.AddGeoreference]: addGeoreference,
  [MutationNames.AddGeoreferenceToQueue]: addGeoreferenceToQueue,
  [MutationNames.SetCELabel]: setCELabel,
  [MutationNames.SetCollectingEvent]: setCollectingEvent,
app/javascript/vue/tasks/extracts/new_extract/store/actions/actions.js on lines 18..33
app/javascript/vue/tasks/extracts/new_extract/store/getters/getters.js on lines 33..48
app/javascript/vue/tasks/observation_matrices/image/store/mutations/mutations.js on lines 33..48
app/javascript/vue/tasks/otu/browse/store/actions/actions.js on lines 17..32
app/javascript/vue/tasks/sources/new_source/store/getters/getters.js on lines 33..48
app/javascript/vue/tasks/sources/new_source/store/mutations/mutations.js on lines 33..48

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

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

export default function (state, args) {
  const {
    descriptorId,
    observationId,
    mean
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setContinuousUnit.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setContinuousValue.js on lines 4..16
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setDayFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setMonthFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleMaxFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleMedian.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleMinFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleNFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleStandardDeviation.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleStandardError.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleUnitFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setTimeFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setYearFor.js on lines 4..13

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

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

export default function (state, args) {
  const {
    descriptorId,
    observationId,
    units
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setContinuousUnit.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setContinuousValue.js on lines 4..16
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setDayFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setMonthFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleMaxFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleMedian.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleMinFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleNFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleStandardDeviation.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleStandardError.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleStandardMean.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setTimeFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setYearFor.js on lines 4..13

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

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

export default function (state, args) {
  const {
    descriptorId,
    observationId,
    standardError
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setContinuousUnit.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setContinuousValue.js on lines 4..16
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setDayFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setMonthFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleMaxFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleMedian.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleMinFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleNFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleStandardDeviation.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleStandardMean.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleUnitFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setTimeFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setYearFor.js on lines 4..13

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

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

export default function (state, args) {
  const {
    descriptorId,
    observationId,
    median
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setContinuousUnit.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setContinuousValue.js on lines 4..16
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setDayFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setMonthFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleMaxFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleMinFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleNFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleStandardDeviation.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleStandardError.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleStandardMean.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleUnitFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setTimeFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setYearFor.js on lines 4..13

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

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

export default function (state, args) {
  const {
    descriptorId,
    observationId,
    n
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setContinuousUnit.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setContinuousValue.js on lines 4..16
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setDayFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setMonthFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleMaxFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleMedian.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleMinFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleStandardDeviation.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleStandardError.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleStandardMean.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleUnitFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setTimeFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setYearFor.js on lines 4..13

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

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

export default function (state, args) {
  const {
    descriptorId,
    observationId,
    time
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setContinuousUnit.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setContinuousValue.js on lines 4..16
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setDayFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setMonthFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleMaxFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleMedian.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleMinFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleNFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleStandardDeviation.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleStandardError.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleStandardMean.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleUnitFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setYearFor.js on lines 4..13

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

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

export default function (state, args) {
  const {
    descriptorId,
    observationId,
    year
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setContinuousUnit.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setContinuousValue.js on lines 4..16
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setDayFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setMonthFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleMaxFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleMedian.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleMinFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleNFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleStandardDeviation.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleStandardError.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleStandardMean.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleUnitFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setTimeFor.js on lines 4..13

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

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

export default function (state, args) {
  const {
    descriptorId,
    continuousValue,
    observationId
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setContinuousUnit.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setDayFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setMonthFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleMaxFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleMedian.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleMinFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleNFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleStandardDeviation.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleStandardError.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleStandardMean.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleUnitFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setTimeFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setYearFor.js on lines 4..13

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

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

export default function (state, args) {
  const {
    descriptorId,
    observationId,
    max
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setContinuousUnit.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setContinuousValue.js on lines 4..16
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setDayFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setMonthFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleMedian.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleMinFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleNFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleStandardDeviation.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleStandardError.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleStandardMean.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleUnitFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setTimeFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setYearFor.js on lines 4..13

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

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

export default function (state, args) {
  const {
    descriptorId,
    observationId,
    month
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setContinuousUnit.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setContinuousValue.js on lines 4..16
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setDayFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleMaxFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleMedian.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleMinFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleNFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleStandardDeviation.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleStandardError.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleStandardMean.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleUnitFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setTimeFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setYearFor.js on lines 4..13

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

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

export default function (state, args) {
  const {
    descriptorId,
    observationId,
    day
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setContinuousUnit.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setContinuousValue.js on lines 4..16
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setMonthFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleMaxFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleMedian.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleMinFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleNFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleStandardDeviation.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleStandardError.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleStandardMean.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleUnitFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setTimeFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setYearFor.js on lines 4..13

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

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

export default function (state, args) {
  const {
    descriptorId,
    continuousUnit,
    observationId
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setContinuousValue.js on lines 4..16
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setDayFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setMonthFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleMaxFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleMedian.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleMinFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleNFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleStandardDeviation.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleStandardError.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleStandardMean.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleUnitFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setTimeFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setYearFor.js on lines 4..13

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

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

export default function (state, args) {
  const {
    descriptorId,
    observationId,
    min
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setContinuousUnit.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setContinuousValue.js on lines 4..16
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setDayFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setMonthFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleMaxFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleMedian.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleNFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleStandardDeviation.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleStandardError.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleStandardMean.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleUnitFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setTimeFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setYearFor.js on lines 4..13

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

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

export default function (state, args) {
  const {
    descriptorId,
    observationId,
    standardDeviation
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setContinuousUnit.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setContinuousValue.js on lines 4..16
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setDayFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setMonthFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleMaxFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleMedian.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleMinFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleNFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleStandardError.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleStandardMean.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setSampleUnitFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setTimeFor.js on lines 4..13
app/javascript/vue/tasks/observation_matrices/matrix_row_coder/store/mutations/setYearFor.js on lines 4..13

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

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

    TaxonDetermination.createBatch(params).then((_) => {
      updateBufferedTable(state.selectedCOIds.length)
      state.collectionObjects = state.collectionObjects.filter(
        ({ id }) => !state.selectedCOIds.includes(id)
      )
app/javascript/vue/tasks/collecting_events/stepwise/collectors/composables/useStore.js on lines 61..72

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

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

    CollectingEvent.batchUpdate(params).then((_) => {
      updateVerbatimTable(state.selectedCEIds.length)
      state.collectingEvents = state.collectingEvents.filter(
        ({ id }) => !state.selectedCEIds.includes(id)
      )
app/javascript/vue/tasks/collection_objects/stepwise/determinations/composables/useStore.js on lines 54..65

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

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 function octagon({ color }, { size }) {
  const element = document.createElementNS(
    'http://www.w3.org/2000/svg',
    'polygon'
  )
Severity: Major
Found in app/javascript/vue/components/ui/VGraph/svg/octagon.js and 1 other location - About 4 hrs to fix
app/javascript/vue/components/ui/VGraph/svg/hexagon.js on lines 1..14

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

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 function hexagon({ color }, { size }) {
  const element = document.createElementNS(
    'http://www.w3.org/2000/svg',
    'polygon'
  )
Severity: Major
Found in app/javascript/vue/components/ui/VGraph/svg/hexagon.js and 1 other location - About 4 hrs to fix
app/javascript/vue/components/ui/VGraph/svg/octagon.js on lines 1..14

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

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

  loadBufferedPage: (page = 1) => {
    const params = {
      ...state.bufferedParams,
      page
    }
app/javascript/vue/tasks/collecting_events/stepwise/collectors/composables/useStore.js on lines 75..91

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

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