department-of-veterans-affairs/vets-website

View on GitHub

Showing 4,231 of 14,884 total issues

Function NotEligible has 57 lines of code (exceeds 25 allowed). Consider refactoring.
Open

export function NotEligible(name) {
  return (
    <>
      <div>
        <va-alert
Severity: Major
Found in src/applications/fry-dea/components/ConfirmationResponses.jsx - About 2 hrs to fix

    Function determineBoardObj has 57 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

    export const determineBoardObj = (formResponses, noDRB) => {
      if (!formResponses) {
        return null;
      }
    
    
    Severity: Major
    Found in src/applications/discharge-wizard/helpers/index.jsx - About 2 hrs to fix

      Function useFocusedElement has 57 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

      export function useFocusedElement() {
        const [focusedElement, setFocusedElement] = useState({
          element: null,
          displayString: '',
        });

        Function generateStatusResponse has 57 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

        const generateStatusResponse = (req, res) => {
          const { id } = req.params;
        
          // increase to use multiple retries
          const requiredRetries = 0;

          Function YourHealthInformation has 57 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

          const YourHealthInformation = props => {
            const { avs } = props;
            const fullState = useSelector(state => state);
          
            const appointmentDate = getFormattedAppointmentDate(avs);
          Severity: Major
          Found in src/applications/avs/components/YourHealthInformation.jsx - About 2 hrs to fix

            Function setupPages has 57 lines of code (exceeds 25 allowed). Consider refactoring.
            Open

            export const setupPages = formConfig => {
              const chapterKeys = Object.keys(formConfig?.chapters || {});
              const chapterTitles = Object.values(formConfig?.chapters || {}).map(
                value => value.title,
              );

              Function ProgramApprovalInformation has 57 lines of code (exceeds 25 allowed). Consider refactoring.
              Open

              const ProgramApprovalInformation = () => {
                return (
                  <MainContentSubDiv
                    id="program-approval-information"
                    header="Program approval information"

                Function NeedsSSNResolution has 57 lines of code (exceeds 25 allowed). Consider refactoring.
                Open

                const NeedsSSNResolution = () => {
                  const content = {
                    heading: 'The information you provided doesn’t match our records',
                    alertText: (
                      <div>

                  Function listItems has 57 lines of code (exceeds 25 allowed). Consider refactoring.
                  Open

                    const listItems = dependents.map((item, index) => {
                      const { fullName, dependentRelation } = item;
                      const dependentName = normalizeFullName(fullName);
                  
                      return (
                  Severity: Major
                  Found in src/applications/hca/components/FormFields/DependentList.jsx - About 2 hrs to fix

                    Function NeedsVAPatient has 57 lines of code (exceeds 25 allowed). Consider refactoring.
                    Open

                    const NeedsVAPatient = () => {
                      const content = {
                        heading: 'We couldn’t match your information to our VA patient records',
                        alertText: (
                          <>

                      Function render has 57 lines of code (exceeds 25 allowed). Consider refactoring.
                      Open

                        render() {
                          if (this.state.messageDismissed) {
                            return this.props.children;
                          }
                      
                      

                        Function TravelClaimCard has 57 lines of code (exceeds 25 allowed). Consider refactoring.
                        Open

                        export default function TravelClaimCard(props) {
                          const {
                            canViewClaimDetails,
                            id,
                            createdOn,
                        Severity: Major
                        Found in src/applications/travel-pay/components/TravelClaimCard.jsx - About 2 hrs to fix

                          Function EmploymentHistoryWidget has 57 lines of code (exceeds 25 allowed). Consider refactoring.
                          Open

                          const EmploymentHistoryWidget = props => {
                            const {
                              goToPath,
                              goForward,
                              contentBeforeButtons,

                            Function SpouseEmploymentHistoryWidget has 57 lines of code (exceeds 25 allowed). Consider refactoring.
                            Open

                            const SpouseEmploymentHistoryWidget = props => {
                              const {
                                goToPath,
                                goForward,
                                contentBeforeButtons,

                              Function calculateHousing has 57 lines of code (exceeds 25 allowed). Consider refactoring.
                              Open

                              function calculateHousing(constant, eligibility, institution, derived) {
                                if (derived.chapter === 31 && derived.isFlightOrCorrespondence) {
                                  return {
                                    qualifier: 'per month',
                                    ratedQualifier: ' / month',
                              Severity: Major
                              Found in src/applications/gi/selectors/estimator.js - About 2 hrs to fix

                                Function fetchCopays has 57 lines of code (exceeds 25 allowed). Consider refactoring.
                                Open

                                export const fetchCopays = () => async dispatch => {
                                  dispatch({ type: COPAYS_FETCH_INITIATED });
                                  const getCopays = () => {
                                    const options = {
                                      method: 'GET',
                                Severity: Major
                                Found in src/applications/personalization/dashboard/actions/debts.js - About 2 hrs to fix

                                  Function generateStatusResponse has 57 lines of code (exceeds 25 allowed). Consider refactoring.
                                  Open

                                  const generateStatusResponse = (req, res) => {
                                    const { id } = req.params;
                                  
                                    // increase to use multiple retries
                                    const requiredRetries = 0;

                                    Function fetchDebts has 57 lines of code (exceeds 25 allowed). Consider refactoring.
                                    Open

                                    export const fetchDebts = () => async dispatch => {
                                      dispatch({ type: DEBTS_FETCH_INITIATED });
                                      const getDebts = () => {
                                        const options = {
                                          method: 'GET',
                                    Severity: Major
                                    Found in src/applications/personalization/dashboard/actions/debts.js - About 2 hrs to fix

                                      Function blueButtonReducer has 57 lines of code (exceeds 25 allowed). Consider refactoring.
                                      Open

                                      export const blueButtonReducer = (state = initialState, action) => {
                                        switch (action.type) {
                                          case Actions.BlueButtonReport.GET: {
                                            const updates = {};
                                      
                                      
                                      Severity: Major
                                      Found in src/applications/mhv-medical-records/reducers/blueButton.js - About 2 hrs to fix

                                        Function generateActivityJournalContent has 57 lines of code (exceeds 25 allowed). Consider refactoring.
                                        Open

                                        export const generateActivityJournalContent = record => {
                                          const content = {
                                            title: record.date,
                                            details: [
                                              {
                                          Severity
                                          Category
                                          Status
                                          Source
                                          Language