department-of-veterans-affairs/vets-website

View on GitHub

Showing 12,835 of 12,835 total issues

Function LessThanFive has 58 lines of code (exceeds 25 allowed). Consider refactoring.
Open

const LessThanFive = () => {
  useEffect(() => {
    recordEvent({
      event: 'howToWizard-alert-displayed',
      'reason-for-alert':

    Function getAllExpenses has 58 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

    export const getAllExpenses = formData => {
      const {
        expenses: {
          creditCardBills = [],
          expenseRecords = [],
    Severity: Major
    Found in src/applications/financial-status-report/utils/calculateExpenses.js - About 2 hrs to fix

      Function handleFiles has 58 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

        const handleFiles = event => {
          const currentTotalSize = attachments.reduce((currentSize, item) => {
            return currentSize + item.size;
          }, 0);
          const selectedFile = event.target.files[0];

        Function fetchPendingAppointments has 58 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

        export function fetchPendingAppointments() {
          return async (dispatch, getState) => {
            try {
              dispatch({
                type: FETCH_PENDING_APPOINTMENTS,
        Severity: Major
        Found in src/applications/vaos/appointment-list/redux/actions.js - About 2 hrs to fix

          Function convertHtmlForDownload has 58 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

          export const convertHtmlForDownload = (html, option) => {
            const $ = cheerio.load(html);
            const contentElements = [
              'address',
              'blockquote',
          Severity: Major
          Found in src/applications/mhv-medications/util/helpers.js - About 2 hrs to fix

            File utilities.js has 263 lines of code (exceeds 250 allowed). Consider refactoring.
            Open

            /* eslint-disable camelcase */
            import environment from 'platform/utilities/environment';
            import recordEvent from 'platform/monitoring/record-event';
            import { teardownProfileSession } from 'platform/user/profile/utilities';
            import { updateLoggedInStatus } from 'platform/user/authentication/actions';
            Severity: Minor
            Found in src/platform/utilities/oauth/utilities.js - About 2 hrs to fix

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

              const isValidPhone = (phone, isInternational) => {
                let stripped;
                try {
                  stripped = phone.replace(/[^\d]/g, '');
                } catch (err) {
              Severity: Major
              Found in src/applications/fry-dea/validation.js and 2 other locations - About 2 hrs to fix
              src/applications/my-education-benefits/utils/validation.js on lines 6..16
              src/applications/toe/utils/validation.js on lines 32..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 81.

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

              const isValidPhone = (phone, isInternational) => {
                let stripped;
                try {
                  stripped = phone.replace(/[^\d]/g, '');
                } catch (err) {
              Severity: Major
              Found in src/applications/toe/utils/validation.js and 2 other locations - About 2 hrs to fix
              src/applications/my-education-benefits/utils/validation.js on lines 6..16
              src/applications/fry-dea/validation.js on lines 5..15

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

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

              export const isValidPhone = (phone, isInternational) => {
                let stripped;
                try {
                  stripped = phone.replace(/[^\d]/g, '');
                } catch (err) {
              Severity: Major
              Found in src/applications/my-education-benefits/utils/validation.js and 2 other locations - About 2 hrs to fix
              src/applications/toe/utils/validation.js on lines 32..42
              src/applications/fry-dea/validation.js on lines 5..15

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

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

                VACCINATED_ADDITIONAL2: {
                  'ui:title': <span>Enter another dose</span>,
                  'ui:reviewField': CustomReviewField,
                  'ui:widget': 'checkbox',
                  'ui:options': {
              src/applications/coronavirus-research/sign-up/pages/covidResearchUISchema.js on lines 444..456
              src/applications/coronavirus-research/sign-up/pages/covidResearchUISchema.js on lines 506..518
              src/applications/coronavirus-research/sign-up/pages/covidResearchUISchema.js on lines 568..580
              src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 218..230
              src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 280..292
              src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 342..354
              src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 404..416

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

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

                VACCINATED_ADDITIONAL2: {
                  'ui:title': <span>Enter another dose</span>,
                  'ui:reviewField': CustomReviewField,
                  'ui:widget': 'checkbox',
                  'ui:options': {
              src/applications/coronavirus-research/sign-up/pages/covidResearchUISchema.js on lines 382..394
              src/applications/coronavirus-research/sign-up/pages/covidResearchUISchema.js on lines 444..456
              src/applications/coronavirus-research/sign-up/pages/covidResearchUISchema.js on lines 506..518
              src/applications/coronavirus-research/sign-up/pages/covidResearchUISchema.js on lines 568..580
              src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 280..292
              src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 342..354
              src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 404..416

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

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

                VACCINATED_ADDITIONAL3: {
                  'ui:title': <span>Enter another dose</span>,
                  'ui:reviewField': CustomReviewField,
                  'ui:widget': 'checkbox',
                  'ui:options': {
              src/applications/coronavirus-research/sign-up/pages/covidResearchUISchema.js on lines 382..394
              src/applications/coronavirus-research/sign-up/pages/covidResearchUISchema.js on lines 506..518
              src/applications/coronavirus-research/sign-up/pages/covidResearchUISchema.js on lines 568..580
              src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 218..230
              src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 280..292
              src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 342..354
              src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 404..416

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

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

                VACCINATED_ADDITIONAL3: {
                  'ui:title': <span>Enter another dose</span>,
                  'ui:reviewField': CustomReviewField,
                  'ui:widget': 'checkbox',
                  'ui:options': {
              src/applications/coronavirus-research/sign-up/pages/covidResearchUISchema.js on lines 382..394
              src/applications/coronavirus-research/sign-up/pages/covidResearchUISchema.js on lines 444..456
              src/applications/coronavirus-research/sign-up/pages/covidResearchUISchema.js on lines 506..518
              src/applications/coronavirus-research/sign-up/pages/covidResearchUISchema.js on lines 568..580
              src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 218..230
              src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 342..354
              src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 404..416

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

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

                VACCINATED_ADDITIONAL5: {
                  'ui:title': <span>Enter another dose</span>,
                  'ui:reviewField': CustomReviewField,
                  'ui:widget': 'checkbox',
                  'ui:options': {
              src/applications/coronavirus-research/sign-up/pages/covidResearchUISchema.js on lines 382..394
              src/applications/coronavirus-research/sign-up/pages/covidResearchUISchema.js on lines 444..456
              src/applications/coronavirus-research/sign-up/pages/covidResearchUISchema.js on lines 506..518
              src/applications/coronavirus-research/sign-up/pages/covidResearchUISchema.js on lines 568..580
              src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 218..230
              src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 280..292
              src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 342..354

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

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

                VACCINATED_ADDITIONAL4: {
                  'ui:title': <span>Enter another dose</span>,
                  'ui:reviewField': CustomReviewField,
                  'ui:widget': 'checkbox',
                  'ui:options': {
              src/applications/coronavirus-research/sign-up/pages/covidResearchUISchema.js on lines 382..394
              src/applications/coronavirus-research/sign-up/pages/covidResearchUISchema.js on lines 444..456
              src/applications/coronavirus-research/sign-up/pages/covidResearchUISchema.js on lines 568..580
              src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 218..230
              src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 280..292
              src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 342..354
              src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 404..416

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

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

                VACCINATED_ADDITIONAL5: {
                  'ui:title': <span>Enter another dose</span>,
                  'ui:reviewField': CustomReviewField,
                  'ui:widget': 'checkbox',
                  'ui:options': {
              src/applications/coronavirus-research/sign-up/pages/covidResearchUISchema.js on lines 382..394
              src/applications/coronavirus-research/sign-up/pages/covidResearchUISchema.js on lines 444..456
              src/applications/coronavirus-research/sign-up/pages/covidResearchUISchema.js on lines 506..518
              src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 218..230
              src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 280..292
              src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 342..354
              src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 404..416

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

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

                VACCINATED_ADDITIONAL4: {
                  'ui:title': <span>Enter another dose</span>,
                  'ui:reviewField': CustomReviewField,
                  'ui:widget': 'checkbox',
                  'ui:options': {
              src/applications/coronavirus-research/sign-up/pages/covidResearchUISchema.js on lines 382..394
              src/applications/coronavirus-research/sign-up/pages/covidResearchUISchema.js on lines 444..456
              src/applications/coronavirus-research/sign-up/pages/covidResearchUISchema.js on lines 506..518
              src/applications/coronavirus-research/sign-up/pages/covidResearchUISchema.js on lines 568..580
              src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 218..230
              src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 280..292
              src/applications/coronavirus-research/update/pages/covidResearchUISchema.js on lines 404..416

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

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

                return (
                  <InputList
                    errorList={errorList}
                    inputs={spAddlIncome}
                    title={title}
              src/applications/financial-status-report/components/householdExpenses/HouseholdExpensesInputList.jsx on lines 42..53
              src/applications/financial-status-report/components/householdIncome/AdditionalIncomeInputList.jsx on lines 41..52
              src/applications/financial-status-report/components/monetary/MonetaryInputList.jsx on lines 78..89
              src/applications/financial-status-report/components/otherExpenses/OtherExpensesInputList.jsx on lines 39..50
              src/applications/financial-status-report/components/utilityBills/UtilityBillInputList.jsx on lines 37..48

              Duplicated Code

              Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

              Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

              When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

              Tuning

              This issue has a mass of 81.

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

                return (
                  <InputList
                    errorList={errorList}
                    inputs={otherExpenses}
                    title={title}
              src/applications/financial-status-report/components/householdExpenses/HouseholdExpensesInputList.jsx on lines 42..53
              src/applications/financial-status-report/components/householdIncome/AdditionalIncomeInputList.jsx on lines 41..52
              src/applications/financial-status-report/components/householdIncome/SpouseAdditionalIncomeInputList.jsx on lines 42..53
              src/applications/financial-status-report/components/monetary/MonetaryInputList.jsx on lines 78..89
              src/applications/financial-status-report/components/utilityBills/UtilityBillInputList.jsx on lines 37..48

              Duplicated Code

              Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

              Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

              When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

              Tuning

              This issue has a mass of 81.

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

                return (
                  <InputList
                    errorList={errorList}
                    inputs={expenseRecords}
                    title={title}
              src/applications/financial-status-report/components/householdIncome/AdditionalIncomeInputList.jsx on lines 41..52
              src/applications/financial-status-report/components/householdIncome/SpouseAdditionalIncomeInputList.jsx on lines 42..53
              src/applications/financial-status-report/components/monetary/MonetaryInputList.jsx on lines 78..89
              src/applications/financial-status-report/components/otherExpenses/OtherExpensesInputList.jsx on lines 39..50
              src/applications/financial-status-report/components/utilityBills/UtilityBillInputList.jsx on lines 37..48

              Duplicated Code

              Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

              Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

              When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

              Tuning

              This issue has a mass of 81.

              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