Skip to content

Commit

Permalink
Refactor SonarCloud suggestions
Browse files Browse the repository at this point in the history
  • Loading branch information
ivangabriele committed Jan 16, 2024
1 parent 63e7470 commit 5840731
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions frontend/src/features/Mission/useCases/addMission.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,12 +12,12 @@ export const addMission =
}): MainAppThunk =>
dispatch => {
const mainFormValues =
initialValues?.mainFormValues || getMissionFormInitialValues(undefined, []).initialMainFormValues
initialValues?.mainFormValues ?? getMissionFormInitialValues(undefined, []).initialMainFormValues

dispatch(
sideWindowDispatchers.openPath({
initialData: {
actionsFormValues: initialValues?.actionsFormValues || [],
actionsFormValues: initialValues?.actionsFormValues ?? [],
mainFormValues
},
menu: SideWindowMenuKey.MISSION_FORM
Expand Down
2 changes: 1 addition & 1 deletion frontend/src/features/SideWindow/MissionForm/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -537,7 +537,7 @@ export function MissionForm() {

const { initialActionsFormValues, initialMainFormValues } = getMissionFormInitialValues(
mission,
missionWithActions?.actions || []
missionWithActions?.actions ?? []
)
const [, { nextActionsFormValues, nextMainFormValues }] = validateMissionForms(
initialMainFormValues,
Expand Down

0 comments on commit 5840731

Please sign in to comment.