Skip to content

Commit

Permalink
Merge pull request #5448 from flexion/10519-bug-intermediate-branch-t…
Browse files Browse the repository at this point in the history
…o-test-1728665114

10519 Bug: 30 Day NOTT Location Display Issue
  • Loading branch information
Mwindo authored Oct 14, 2024
2 parents 9cb405b + 2ffb0bb commit 51040b3
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -135,7 +135,7 @@ describe('serveThirtyDayNoticeInteractor', () => {
trialLocation: {
address1: trialSession.address1!,
address2: trialSession.address2!,
cityState: trialSession.trialLocation,
cityState: `${trialSession.city}, ${trialSession.state}`,
courthouseName: trialSession.courthouseName!,
postalCode: trialSession.postalCode!,
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -138,6 +138,17 @@ export const serveThirtyDayNoticeInteractor = async (
caseCaption: caseEntity.caseCaption,
});

const formatCityState = ({
city,
state,
}: {
city?: string;
state?: string;
}) => {
const formattedString = [city, state].filter(Boolean).join(', ');
return formattedString;
};

let noticePdf = await applicationContext
.getDocumentGenerators()
.thirtyDayNoticeOfTrial({
Expand All @@ -158,7 +169,10 @@ export const serveThirtyDayNoticeInteractor = async (
trialLocation: {
address1: trialSession.address1,
address2: trialSession.address2,
cityState: trialSession.trialLocation,
cityState: formatCityState({
city: trialSession.city,
state: trialSession.state,
}),
courthouseName: trialSession.courthouseName,
postalCode: trialSession.postalCode,
},
Expand Down

0 comments on commit 51040b3

Please sign in to comment.