File tree Expand file tree Collapse file tree 1 file changed +7
-3
lines changed
src/main/java/uk/gov/companieshouse/pscdataapi/service Expand file tree Collapse file tree 1 file changed +7
-3
lines changed Original file line number Diff line number Diff line change @@ -212,9 +212,13 @@ public PscIndividualFullRecordApi getIndividualFullRecord(final String companyNu
212212 }
213213
214214 if (featureFlags .isIndividualPscFullRecordAddVerificationStateEnabled ()) {
215- oracleQueryApiService .getPscVerificationState (individualFullRecord .getInternalId ())
216- .map (verificationStateMapper ::mapToVerificationState )
217- .ifPresent (individualFullRecord ::setVerificationState );
215+ if (individualFullRecord .getInternalId () != null ) {
216+ oracleQueryApiService .getPscVerificationState (individualFullRecord .getInternalId ())
217+ .map (verificationStateMapper ::mapToVerificationState )
218+ .ifPresent (individualFullRecord ::setVerificationState );
219+ } else {
220+ logger .error ("Internal ID not found in PSC document." , DataMapHolder .getLogMap ());
221+ }
218222 }
219223 return individualFullRecord ;
220224
You can’t perform that action at this time.
0 commit comments