department-of-veterans-affairs/vets-website

View on GitHub

Showing 12,675 of 12,675 total issues

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

export const addIncludedIssues = formData => {
  const issues = getContestableIssues(formData);

  const result = issues.concat(
    (formData.additionalIssues || []).reduce((issuesToAdd, issue) => {
Severity: Major
Found in src/applications/appeals/10182/utils/submit.js and 1 other location - About 6 hrs to fix
src/applications/appeals/shared/utils/submit.js on lines 84..104

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

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

      cy.intercept(`/check_in/v2/patient_check_ins/*`, { times: 1 }, req => {
        const rv = sharedData.get.createAppointments(
          token,
          demographicsNeedsUpdate,
          demographicsConfirmedAt,
src/applications/check-in/api/local-mock-api/e2e/ApiInitializer.js on lines 372..399

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

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 const HCA_ENROLLMENT_STATUSES = Object.freeze({
  activeDuty: 'activeduty',
  canceledDeclined: 'canceled_declined',
  closed: 'closed',
  deceased: 'deceased',
Severity: Major
Found in src/applications/hca/utils/constants.js and 1 other location - About 6 hrs to fix
src/platform/user/profile/constants/hca.js on lines 53..81

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

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

Function RadiologySingleImage has 153 lines of code (exceeds 25 allowed). Consider refactoring.
Open

const RadiologySingleImage = () => {
  const dispatch = useDispatch();
  const { labId, imageId } = useParams();
  // const labAndTestDetails = useSelector(
  //   state => state.mr.labsAndTests.labsAndTestsDetails,

    Function content has 153 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

      const content = () => {
        if (!showRefillContent) {
          return <PageNotFound />;
        }
        if (isLoading) {
    Severity: Major
    Found in src/applications/mhv-medications/containers/RefillPrescriptions.jsx - About 6 hrs to fix

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

      export default {
        uiSchema: {
          toursOfDuty: {
            'ui:title': 'Service periods',
            'ui:options': {
      src/applications/edu-benefits/10215/pages/serviceHistory.js on lines 15..62
      src/applications/edu-benefits/10216/pages/serviceHistory.js on lines 15..62
      src/applications/edu-benefits/10282/pages/serviceHistory.js on lines 15..62
      src/applications/edu-benefits/1919/pages/serviceHistory.js on lines 15..62
      src/applications/edu-benefits/8794/pages/serviceHistory.js on lines 15..62

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

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

      export default {
        uiSchema: {
          toursOfDuty: {
            'ui:title': 'Service periods',
            'ui:options': {
      Severity: Major
      Found in src/applications/edu-benefits/10282/pages/serviceHistory.js and 5 other locations - About 6 hrs to fix
      src/applications/edu-benefits/10215/pages/serviceHistory.js on lines 15..62
      src/applications/edu-benefits/10216/pages/serviceHistory.js on lines 15..62
      src/applications/edu-benefits/1919/pages/serviceHistory.js on lines 15..62
      src/applications/edu-benefits/8794/pages/serviceHistory.js on lines 15..62
      src/applications/survivor-dependent-education-benefit/22-5490/pages/serviceHistory.js on lines 15..62

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

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

      export default {
        uiSchema: {
          toursOfDuty: {
            'ui:title': 'Service periods',
            'ui:options': {
      Severity: Major
      Found in src/applications/edu-benefits/1919/pages/serviceHistory.js and 5 other locations - About 6 hrs to fix
      src/applications/edu-benefits/10215/pages/serviceHistory.js on lines 15..62
      src/applications/edu-benefits/10216/pages/serviceHistory.js on lines 15..62
      src/applications/edu-benefits/10282/pages/serviceHistory.js on lines 15..62
      src/applications/edu-benefits/8794/pages/serviceHistory.js on lines 15..62
      src/applications/survivor-dependent-education-benefit/22-5490/pages/serviceHistory.js on lines 15..62

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

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

      export default {
        uiSchema: {
          toursOfDuty: {
            'ui:title': 'Service periods',
            'ui:options': {
      Severity: Major
      Found in src/applications/edu-benefits/10215/pages/serviceHistory.js and 5 other locations - About 6 hrs to fix
      src/applications/edu-benefits/10216/pages/serviceHistory.js on lines 15..62
      src/applications/edu-benefits/10282/pages/serviceHistory.js on lines 15..62
      src/applications/edu-benefits/1919/pages/serviceHistory.js on lines 15..62
      src/applications/edu-benefits/8794/pages/serviceHistory.js on lines 15..62
      src/applications/survivor-dependent-education-benefit/22-5490/pages/serviceHistory.js on lines 15..62

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

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

      export default {
        uiSchema: {
          toursOfDuty: {
            'ui:title': 'Service periods',
            'ui:options': {
      Severity: Major
      Found in src/applications/edu-benefits/10216/pages/serviceHistory.js and 5 other locations - About 6 hrs to fix
      src/applications/edu-benefits/10215/pages/serviceHistory.js on lines 15..62
      src/applications/edu-benefits/10282/pages/serviceHistory.js on lines 15..62
      src/applications/edu-benefits/1919/pages/serviceHistory.js on lines 15..62
      src/applications/edu-benefits/8794/pages/serviceHistory.js on lines 15..62
      src/applications/survivor-dependent-education-benefit/22-5490/pages/serviceHistory.js on lines 15..62

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

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

      export default {
        uiSchema: {
          toursOfDuty: {
            'ui:title': 'Service periods',
            'ui:options': {
      Severity: Major
      Found in src/applications/edu-benefits/8794/pages/serviceHistory.js and 5 other locations - About 6 hrs to fix
      src/applications/edu-benefits/10215/pages/serviceHistory.js on lines 15..62
      src/applications/edu-benefits/10216/pages/serviceHistory.js on lines 15..62
      src/applications/edu-benefits/10282/pages/serviceHistory.js on lines 15..62
      src/applications/edu-benefits/1919/pages/serviceHistory.js on lines 15..62
      src/applications/survivor-dependent-education-benefit/22-5490/pages/serviceHistory.js on lines 15..62

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

      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: '3258313',
            type: 'message_details',
            attributes: {
              messageId: 3258313,
      src/platform/mhv/api/mocks/secure-messaging/messages/messageDetails.js on lines 34..62
      src/platform/mhv/api/mocks/secure-messaging/messages/messageDetails.js on lines 92..120
      src/platform/mhv/api/mocks/secure-messaging/messages/messageDetails.js on lines 150..178

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

      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: '3400519',
            type: 'message_details',
            attributes: {
              messageId: 3400519,
      src/platform/mhv/api/mocks/secure-messaging/messages/messageDetails.js on lines 34..62
      src/platform/mhv/api/mocks/secure-messaging/messages/messageDetails.js on lines 92..120
      src/platform/mhv/api/mocks/secure-messaging/messages/messageDetails.js on lines 179..207

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

      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

        setOptions = options => {
          if (!this.unmounted) {
            const suggestions = this.getSuggestions(options, this.state.input);
            this.setState({
              options,
      src/platform/forms-system/src/js/fields/AutosuggestField.jsx on lines 88..106

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

      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: '3550426',
            type: 'message_details',
            attributes: {
              messageId: 3550426,
      src/platform/mhv/api/mocks/secure-messaging/messages/messageDetails.js on lines 92..120
      src/platform/mhv/api/mocks/secure-messaging/messages/messageDetails.js on lines 150..178
      src/platform/mhv/api/mocks/secure-messaging/messages/messageDetails.js on lines 179..207

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

      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

        setOptions = options => {
          if (!this.unmounted) {
            const suggestions = this.getSuggestions(options, this.state.input);
            this.setState({
              options,
      Severity: Major
      Found in src/platform/forms-system/src/js/fields/AutosuggestField.jsx and 1 other location - About 6 hrs to fix
      src/applications/pre-need-integration/components/AutosugggestField.jsx on lines 89..107

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

      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: '3549585',
            type: 'message_details',
            attributes: {
              messageId: 3549585,
      src/platform/mhv/api/mocks/secure-messaging/messages/messageDetails.js on lines 34..62
      src/platform/mhv/api/mocks/secure-messaging/messages/messageDetails.js on lines 150..178
      src/platform/mhv/api/mocks/secure-messaging/messages/messageDetails.js on lines 179..207

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

      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

                <div className="vads-grid-col">
                  <VaRadio
                    uswds
                    label="V3 Radio"
                    onVaValueChange={e => updateRadioValue(e.detail, 'v3')}
      Severity: Major
      Found in src/applications/ds-v3-playground/pages/V3BasePage.jsx and 1 other location - About 6 hrs to fix
      src/applications/ds-playground/pages/V1V3Page.jsx on lines 239..266

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

      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

          {
            id: '3004676',
            type: 'message_details',
            attributes: {
              messageId: 3004676,
      src/platform/mhv/api/mocks/secure-messaging/messages/messageDetails.js on lines 952..991

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

      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

                  'view:internationalTextMessageAlert': {
                    'ui:description': (
                      <va-alert status="warning">
                        <>
                          You can’t choose to get text notifications because you have
      Severity: Major
      Found in src/applications/toe/config/form.js and 1 other location - About 6 hrs to fix
      src/applications/fry-dea/config/form.js on lines 1136..1166

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

      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