department-of-veterans-affairs/vets-website

View on GitHub

Showing 12,841 of 12,841 total issues

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

  VACCINATED_ADDITIONAL_DATE4: {
    ...currentOrPastMonthYearUI('Month/Year of dose'),
    'ui:options': {
      expandUnder: 'vaccinated',
      monthYear: true,
src/applications/coronavirus-research/sign-up/pages/covidResearchUISchema.js on lines 370..381
src/applications/coronavirus-research/sign-up/pages/covidResearchUISchema.js on lines 432..443
src/applications/coronavirus-research/sign-up/pages/covidResearchUISchema.js on lines 494..505
src/applications/coronavirus-research/sign-up/pages/covidResearchUISchema.js on lines 618..629
src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 206..217
src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 268..279
src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 330..341
src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 392..403
src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 454..465

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

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

  VACCINATED_ADDITIONAL_DATE3: {
    ...currentOrPastMonthYearUI('Month/Year of dose'),
    'ui:options': {
      expandUnder: 'vaccinated',
      monthYear: true,
src/applications/coronavirus-research/sign-up/pages/covidResearchUISchema.js on lines 370..381
src/applications/coronavirus-research/sign-up/pages/covidResearchUISchema.js on lines 432..443
src/applications/coronavirus-research/sign-up/pages/covidResearchUISchema.js on lines 556..567
src/applications/coronavirus-research/sign-up/pages/covidResearchUISchema.js on lines 618..629
src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 206..217
src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 268..279
src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 330..341
src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 392..403
src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 454..465

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

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

  VACCINATED_ADDITIONAL_DATE2: {
    ...currentOrPastMonthYearUI('Month/Year of dose'),
    'ui:options': {
      expandUnder: 'vaccinated',
      monthYear: true,
src/applications/coronavirus-research/sign-up/pages/covidResearchUISchema.js on lines 370..381
src/applications/coronavirus-research/sign-up/pages/covidResearchUISchema.js on lines 494..505
src/applications/coronavirus-research/sign-up/pages/covidResearchUISchema.js on lines 556..567
src/applications/coronavirus-research/sign-up/pages/covidResearchUISchema.js on lines 618..629
src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 206..217
src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 268..279
src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 330..341
src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 392..403
src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 454..465

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

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

  VACCINATED_ADDITIONAL_DATE4: {
    ...currentOrPastMonthYearUI('Month/Year of dose'),
    'ui:options': {
      expandUnder: 'vaccinated',
      monthYear: true,
src/applications/coronavirus-research/sign-up/pages/covidResearchUISchema.js on lines 370..381
src/applications/coronavirus-research/sign-up/pages/covidResearchUISchema.js on lines 432..443
src/applications/coronavirus-research/sign-up/pages/covidResearchUISchema.js on lines 494..505
src/applications/coronavirus-research/sign-up/pages/covidResearchUISchema.js on lines 556..567
src/applications/coronavirus-research/sign-up/pages/covidResearchUISchema.js on lines 618..629
src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 206..217
src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 268..279
src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 330..341
src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 454..465

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

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

  VACCINATED_ADDITIONAL_DATE1: {
    ...currentOrPastMonthYearUI('Month/Year of dose'),
    'ui:options': {
      expandUnder: 'vaccinated',
      monthYear: true,
src/applications/coronavirus-research/sign-up/pages/covidResearchUISchema.js on lines 432..443
src/applications/coronavirus-research/sign-up/pages/covidResearchUISchema.js on lines 494..505
src/applications/coronavirus-research/sign-up/pages/covidResearchUISchema.js on lines 556..567
src/applications/coronavirus-research/sign-up/pages/covidResearchUISchema.js on lines 618..629
src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 206..217
src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 268..279
src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 330..341
src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 392..403
src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 454..465

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

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

  VACCINATED_ADDITIONAL_DATE2: {
    ...currentOrPastMonthYearUI('Month/Year of dose'),
    'ui:options': {
      expandUnder: 'vaccinated',
      monthYear: true,
src/applications/coronavirus-research/sign-up/pages/covidResearchUISchema.js on lines 370..381
src/applications/coronavirus-research/sign-up/pages/covidResearchUISchema.js on lines 432..443
src/applications/coronavirus-research/sign-up/pages/covidResearchUISchema.js on lines 494..505
src/applications/coronavirus-research/sign-up/pages/covidResearchUISchema.js on lines 556..567
src/applications/coronavirus-research/sign-up/pages/covidResearchUISchema.js on lines 618..629
src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 206..217
src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 330..341
src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 392..403
src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 454..465

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

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

  VACCINATED_ADDITIONAL_DATE5: {
    ...currentOrPastMonthYearUI('Month/Year of dose'),
    'ui:options': {
      expandUnder: 'vaccinated',
      monthYear: true,
src/applications/coronavirus-research/sign-up/pages/covidResearchUISchema.js on lines 370..381
src/applications/coronavirus-research/sign-up/pages/covidResearchUISchema.js on lines 432..443
src/applications/coronavirus-research/sign-up/pages/covidResearchUISchema.js on lines 494..505
src/applications/coronavirus-research/sign-up/pages/covidResearchUISchema.js on lines 556..567
src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 206..217
src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 268..279
src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 330..341
src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 392..403
src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 454..465

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

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

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

    return {
      name: 'ANKLE LEFT 3 VIEWS',
      category: 'Radiology',
      orderedBy: 'DOE, JANE A',
      reason: 'Injury',
src/applications/mhv-medical-records/containers/RadiologyImagesList.jsx on lines 26..52

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

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

      <RecordListSection
        accessAlert={activeAlert && activeAlert.type === ALERT_TYPE_ERROR}
        accessAlertType={accessAlertTypes.LABS_AND_TESTS}
        recordCount={labsAndTests?.length}
        recordType={recordType.LABS_AND_TESTS}
src/applications/mhv-medical-records/containers/CareSummariesAndNotes.jsx on lines 79..105
src/applications/mhv-medical-records/containers/HealthConditions.jsx on lines 71..105
src/applications/mhv-medical-records/containers/Vaccines.jsx on lines 162..191

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

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

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

        <DowntimeNotification
          appTitle="application"
          render={this.renderDowntime}
          dependencies={downtimeDependencies}
          customText={formConfig.customText}
src/platform/forms-system/src/js/review/ReviewPage.jsx on lines 31..42

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

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

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

  describe('fetchResultsFailure', () => {
    it('should return an action in the shape we expect', () => {
      const action = fetchResultsFailure('test');

      expect(action).to.be.deep.equal({
src/applications/yellow-ribbon/actions/index.unit.spec.js on lines 35..44

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

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

    claimantContactInformationChapter: {
      title: formData => claimantContactInformationTitle(formData),
      pages: {
        claimantContactInformation: {
          path: 'claimant-contact-information',
Severity: Major
Found in src/applications/simple-forms/21-0972/config/form.js and 3 other locations - About 2 hrs to fix
src/applications/simple-forms/21-0972/config/form.js on lines 186..197
src/applications/simple-forms/21-0972/config/form.js on lines 198..209
src/applications/simple-forms/21-0972/config/form.js on lines 210..221

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

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

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

  describe('fetchResultsFailure', () => {
    it('should return an action in the shape we expect', () => {
      const action = fetchResultsFailure('test');

      expect(action).to.be.deep.equal({
Severity: Major
Found in src/applications/yellow-ribbon/actions/index.unit.spec.js and 1 other location - About 2 hrs to fix
src/applications/third-party-app-directory/actions/index.unit.spec.js on lines 32..41

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

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

      <RecordListSection
        accessAlert={activeAlert && activeAlert.type === ALERT_TYPE_ERROR}
        accessAlertType={accessAlertTypes.CARE_SUMMARIES_AND_NOTES}
        recordCount={careSummariesAndNotes?.length}
        recordType={recordType.CARE_SUMMARIES_AND_NOTES}
src/applications/mhv-medical-records/containers/HealthConditions.jsx on lines 71..105
src/applications/mhv-medical-records/containers/LabsAndTests.jsx on lines 75..97
src/applications/mhv-medical-records/containers/Vaccines.jsx on lines 162..191

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

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

    claimantPersonalInformationChapter: {
      title: formData => claimantPersonalInformationTitle(formData),
      pages: {
        claimantPersonalInformation: {
          path: 'claimant-personal-information',
Severity: Major
Found in src/applications/simple-forms/21-0972/config/form.js and 3 other locations - About 2 hrs to fix
src/applications/simple-forms/21-0972/config/form.js on lines 198..209
src/applications/simple-forms/21-0972/config/form.js on lines 210..221
src/applications/simple-forms/21-0972/config/form.js on lines 222..233

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

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

    claimantAddressChapter: {
      title: formData => claimantAddressTitle(formData),
      pages: {
        claimantAddress: {
          path: 'claimant-address',
Severity: Major
Found in src/applications/simple-forms/21-0972/config/form.js and 3 other locations - About 2 hrs to fix
src/applications/simple-forms/21-0972/config/form.js on lines 186..197
src/applications/simple-forms/21-0972/config/form.js on lines 198..209
src/applications/simple-forms/21-0972/config/form.js on lines 222..233

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

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

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

        <DowntimeNotification
          appTitle="application"
          render={this.renderDowntime}
          dependencies={downtimeDependencies}
          customText={formConfig.customText}
Severity: Major
Found in src/platform/forms-system/src/js/review/ReviewPage.jsx and 1 other location - About 2 hrs to fix
src/platform/forms/save-in-progress/RoutedSavableReviewPage.jsx on lines 72..83

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

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

      <RecordListSection
        accessAlert={activeAlert && activeAlert.type === ALERT_TYPE_ERROR}
        accessAlertType={accessAlertTypes.HEALTH_CONDITIONS}
        recordCount={conditions?.length}
        recordType={recordType.HEALTH_CONDITIONS}
src/applications/mhv-medical-records/containers/CareSummariesAndNotes.jsx on lines 79..105
src/applications/mhv-medical-records/containers/LabsAndTests.jsx on lines 75..97
src/applications/mhv-medical-records/containers/Vaccines.jsx on lines 162..191

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

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

    claimantSsnChapter: {
      title: formData => claimantSsnTitle(formData),
      pages: {
        claimantSsn: {
          path: 'claimant-identification-information',
Severity: Major
Found in src/applications/simple-forms/21-0972/config/form.js and 3 other locations - About 2 hrs to fix
src/applications/simple-forms/21-0972/config/form.js on lines 186..197
src/applications/simple-forms/21-0972/config/form.js on lines 210..221
src/applications/simple-forms/21-0972/config/form.js on lines 222..233

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

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

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

  const labAndTestDetails = {
    name: 'ANKLE LEFT 3 VIEWS',
    category: 'Radiology',
    orderedBy: 'DOE, JANE A',
    reason: 'Injury',
src/applications/mhv-medical-records/containers/RadiologySingleImage.jsx on lines 14..40

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

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