Showing 3,724 of 12,675 total issues
Function clearSpouseData
has 26 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
const clearSpouseData = formData => {
return {
...formData,
questions: {
...formData.questions,
Function saveDraft
has 26 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
export const saveDraft = (messageData, type, id) => async dispatch => {
recordEvent({
// For Google Analytics
event: 'secure-messaging-save-draft-type',
'secure-messaging-save-draft': type,
Function WelcomeMessage
has 26 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
const WelcomeMessage = () => {
const fullState = useSelector(state => state);
return (
<div className="welcome-message">
Function contentT30
has 26 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
() => {
return (
isTranstioningFacility && (
<va-alert status="warning" class="vads-u-margin-y--2">
<h1 slot="headline">
Function appointmentIcon
has 26 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
const appointmentIcon = appointment => {
const isPhone = isVAPhoneAppointment(appointment);
const {
isCommunityCare,
isCompAndPenAppointment,
Function transformFormToVAOSVARequest
has 26 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
export function transformFormToVAOSVARequest(state) {
const data = getFormData(state);
const typeOfCare = getTypeOfCare(data);
return {
Function getAppointmentTimezone
has 26 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
export function getAppointmentTimezone(appointment) {
// Appointments with timezone included in api
if (appointment?.timezone) {
const abbreviation = getTimezoneAbbrFromApi(appointment);
Function renderTuitionAssist
has 26 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
const renderTuitionAssist = () => {
if (!displayedInputs.tuitionAssist) return null;
const tuitionAssistId = 'tuitionAssist';
const tuitionAssistFieldId = `${tuitionAssistId}-field`;
return (
Function renderTuition
has 26 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
const renderTuition = () => {
if (!displayedInputs.tuition) return null;
const tuitionFeesId = 'tuitionFees';
const tuitionFeesFieldId = `${tuitionFeesId}-field`;
Function renderScholarships
has 26 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
const renderScholarships = () => {
if (!displayedInputs.scholarships) return null;
const scholarshipsId = 'scholarships';
const scholarshipsFieldId = `${scholarshipsId}-field`;
return (
Function fetchNameAutocompleteSuggestions
has 26 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
export function fetchNameAutocompleteSuggestions(name, filterFields, version) {
if (name === '' || name === null || name === undefined) {
return { type: NAME_AUTOCOMPLETE_SUCCEEDED, payload: [] };
}
Function loadConnectedApps
has 26 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
export function loadConnectedApps() {
return async dispatch => {
recordEvent({ event: 'profile-get-connected-apps-started' });
dispatch({ type: LOADING_CONNECTED_APPS });
Function deepEqual
has 26 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function deepEqual(obj1, obj2) {
if (obj1 === obj2) return true;
if (
typeof obj1 !== 'object' ||
Function fetchResultsApi
has 26 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
export const fetchResultsApi = async (options = {}) => {
// Derive options properties.
const city = options?.city;
const contribution_amount = options?.contributionAmount;
const mockRequest = options?.mockRequest;
Function getCemeteries
has 26 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
export function getCemeteries() {
return fetch(`${environment.API_URL}/v0/preneeds/cemeteries`, {
credentials: 'include',
headers: {
'X-Key-Inflection': 'camel',
Function uiSchema
has 26 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
export function uiSchema(
subHeader = veteranApplicantDetailsSubHeader,
description = '',
nameUI = nonPreparerFullMaidenNameUI,
ssnUI = ssnDashesUI,
Function allDependents
has 26 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function allDependents(state = initialState, action) {
switch (action.type) {
case FETCH_ALL_DEPENDENTS_SUCCESS:
if (action.response.persons && action.response.persons.length > 0) {
allPeople = splitPersons(action.response.persons);
Function useAlerts
has 26 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
const useAlerts = dispatch => {
const alertList = useSelector(state => state.mr.alerts?.alertList);
const [activeAlert, setActiveAlert] = useState();
useEffect(
Function UNSAFE_componentWillReceiveProps
has 26 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
UNSAFE_componentWillReceiveProps(nextProps) {
// Once the login logic is all done...
// This will occur even for unauthenticated users and should only occur once.
if (this.props.user.profile.loading && !nextProps.user.profile.loading) {
const userProfile = nextProps.user.profile;
Function submitEmail
has 26 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
export function submitEmail(email) {
recordEvent({ event: 'vic-email-started' });
return dispatch => {
dispatch({ type: VIC_EMAIL_CAPTURING });