Skip to content

Commit

Permalink
feat(vta-1674): logic to cater for missing country on test station
Browse files Browse the repository at this point in the history
  • Loading branch information
m-coslett committed Jul 26, 2023
1 parent 815b4c2 commit 16958a0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/services/CertificateGenerationService.ts
Original file line number Diff line number Diff line change
Expand Up @@ -208,7 +208,7 @@ class CertificateGenerationService {
if ((pNumberTestStation) && (pNumberTestStation.length > 0)) {
const thisTestStation = pNumberTestStation[0];
// @ts-ignore
if (thisTestStation.testStationCountry.toUpperCase() === ATF_COUNTRIES.WALES) {
if ((thisTestStation.testStationCountry) && (thisTestStation.testStationCountry.toUpperCase() === ATF_COUNTRIES.WALES)) {
isWelsh = true;
}
console.log(`Test station details: ${thisTestStation.testStationPNumber} ${thisTestStation.testStationName} in ${thisTestStation.testStationCountry}`);
Expand Down

0 comments on commit 16958a0

Please sign in to comment.