department-of-veterans-affairs/vets-website

View on GitHub

Showing 12,814 of 12,814 total issues

File helpers.js has 329 lines of code (exceeds 250 allowed). Consider refactoring.
Open

import appendQuery from 'append-query';
import * as Sentry from '@sentry/browser';
import React from 'react';
import fullSchema from 'vets-json-schema/dist/FEEDBACK-TOOL-schema.json';
import { transformForSubmit } from 'platform/forms-system/src/js/helpers';
Severity: Minor
Found in src/applications/edu-benefits/feedback-tool/helpers.js - About 3 hrs to fix

    Function GuardianInformation has 97 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

    export default function GuardianInformation(schema, options) {
      // Use the defaults as necessary, but override with the options given
      const { fields, required } = {
        ...defaults(),
        ...options,
    Severity: Major
    Found in src/applications/edu-benefits/5490/components/GuardianInformation.jsx - About 3 hrs to fix

      Function App has 97 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

      const App = props => {
        const {
          children,
          location,
          setFormData,
      Severity: Major
      Found in src/applications/hca/containers/App.jsx - About 3 hrs to fix

        Function IdentityPage has 97 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

        const IdentityPage = props => {
          const { router } = props;
          const {
            statusCode,
            vesRecordFound,
        Severity: Major
        Found in src/applications/hca/containers/IdentityPage.jsx - About 3 hrs to fix

          Function CategorySelectPage has 97 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

          const CategorySelectPage = props => {
            const { onChange, loggedIn, goBack, goToPath, formData } = props;
            const dispatch = useDispatch();
          
            const [apiData, setApiData] = useState([]);
          Severity: Major
          Found in src/applications/ask-va/containers/CategorySelectPage.jsx - About 3 hrs to fix

            Function MessageReply has 97 lines of code (exceeds 25 allowed). Consider refactoring.
            Open

            const MessageReply = () => {
              const dispatch = useDispatch();
              const { replyId } = useParams();
              const { drafts, error, messages } = useSelector(
                state => state.sm.threadDetails,
            Severity: Major
            Found in src/applications/mhv-secure-messaging/containers/MessageReply.jsx - About 3 hrs to fix

              File form.js has 328 lines of code (exceeds 250 allowed). Consider refactoring.
              Open

              // this form does NOT use JSON schema for its data model
              import environment from '@department-of-veterans-affairs/platform-utilities/environment';
              import footerContent from 'platform/forms/components/FormFooter';
              
              import manifest from '../manifest.json';
              Severity: Minor
              Found in src/applications/simple-forms/21-0845/config/form.js - About 3 hrs to fix

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

                          {
                            resourceType: 'Observation',
                            id: '12343',
                            basedOn: [
                              {
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 342..377
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 378..413
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 768..803
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 835..870
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 871..906
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 1554..1589
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 1668..1703
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 2621..2656
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 2688..2723
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 2724..2759

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

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

                          {
                            resourceType: 'Observation',
                            id: '12356',
                            basedOn: [
                              {
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 244..279
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 342..377
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 378..413
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 768..803
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 871..906
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 1554..1589
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 1668..1703
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 2621..2656
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 2688..2723
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 2724..2759

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

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

                          {
                            resourceType: 'Observation',
                            id: '12371',
                            basedOn: [
                              {
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 244..279
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 342..377
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 378..413
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 768..803
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 835..870
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 871..906
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 1668..1703
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 2621..2656
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 2688..2723
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 2724..2759

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

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

                          {
                            resourceType: 'Observation',
                            id: '12393',
                            basedOn: [
                              {
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 244..279
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 342..377
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 378..413
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 768..803
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 835..870
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 871..906
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 1554..1589
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 1668..1703
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 2688..2723
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 2724..2759

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

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

                          {
                            resourceType: 'Observation',
                            id: '12395',
                            basedOn: [
                              {
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 244..279
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 342..377
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 378..413
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 768..803
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 835..870
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 871..906
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 1554..1589
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 1668..1703
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 2621..2656
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 2724..2759

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

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

                          {
                            resourceType: 'Observation',
                            id: '12354',
                            basedOn: [
                              {
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 244..279
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 342..377
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 378..413
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 835..870
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 871..906
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 1554..1589
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 1668..1703
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 2621..2656
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 2688..2723
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 2724..2759

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

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

                          {
                            resourceType: 'Observation',
                            id: '12347',
                            basedOn: [
                              {
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 244..279
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 342..377
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 768..803
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 835..870
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 871..906
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 1554..1589
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 1668..1703
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 2621..2656
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 2688..2723
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 2724..2759

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

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

                          {
                            resourceType: 'Observation',
                            id: '12357',
                            basedOn: [
                              {
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 244..279
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 342..377
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 378..413
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 768..803
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 835..870
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 1554..1589
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 1668..1703
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 2621..2656
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 2688..2723
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 2724..2759

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

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

                          {
                            resourceType: 'Observation',
                            id: '12346',
                            basedOn: [
                              {
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 244..279
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 378..413
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 768..803
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 835..870
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 871..906
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 1554..1589
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 1668..1703
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 2621..2656
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 2688..2723
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 2724..2759

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

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

                          {
                            resourceType: 'Observation',
                            id: '12375',
                            basedOn: [
                              {
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 244..279
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 342..377
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 378..413
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 768..803
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 835..870
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 871..906
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 1554..1589
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 2621..2656
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 2688..2723
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 2724..2759

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

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

                          {
                            resourceType: 'Observation',
                            id: '12396',
                            basedOn: [
                              {
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 244..279
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 342..377
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 378..413
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 768..803
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 835..870
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 871..906
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 1554..1589
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 1668..1703
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 2621..2656
                src/platform/mhv/api/mocks/medical-records/labs-and-tests/index.js on lines 2688..2723

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

                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

                    <div className="vads-u-margin-y--2" id={id}>
                      <va-alert
                        close-btn-aria-label="Close notification"
                        status={status}
                        uswds
                Severity: Major
                Found in src/applications/verify-your-enrollment/components/Alert.jsx and 1 other location - About 3 hrs to fix
                src/applications/personalization/profile/components/direct-deposit/vye/components/Alert.jsx on lines 22..36

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

                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

                    {
                      id: '8a4812b77035101201703a2086750033',
                      type: 'cc_appointments',
                      attributes: {
                        appointmentRequestId: '8a4812b77035101201703a2086750033',
                src/applications/personalization/dashboard/utils/mocks/appointments/MOCK_CC_APPOINTMENTS_OVER_30_DAYS.js on lines 25..44
                src/applications/personalization/dashboard/utils/mocks/appointments/MOCK_CC_APPOINTMENTS_OVER_30_DAYS.js on lines 45..64
                src/applications/personalization/dashboard/utils/mocks/appointments/MOCK_CC_APPOINTMENTS_OVER_30_DAYS.js on lines 65..85

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

                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