Skip to content

Commit

Permalink
Change default value of custodianInformation on TEMPO node creation (#…
Browse files Browse the repository at this point in the history
…1160)

Signed-off-by: Angelica Ochoa <[email protected]>
  • Loading branch information
ao508 authored May 15, 2024
1 parent aa38403 commit 7a9cd34
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -39,13 +39,13 @@ public Tempo saveTempoData(Tempo tempo) throws Exception {
// custodian information and data access level
SmileSample sample = tempo.getSmileSample();
SmileRequest request = requestService.getRequestBySample(sample);
String custodianInformation = Strings.isBlank(request.getPiEmail())
? request.getInvestigatorEmail() : request.getPiEmail();
String custodianInformation = Strings.isBlank(request.getLabHeadName())
? request.getLabHeadName() : request.getInvestigatorName();
tempo.setCustodianInformation(custodianInformation);

// if backfilling data then access level might already be present in incoming data
if (Strings.isBlank(tempo.getAccessLevel())) {
tempo.setAccessLevel("MSKEmbargo");
tempo.setAccessLevel("MSK Embargo");
}

return tempoRepository.save(tempo);
Expand Down

0 comments on commit 7a9cd34

Please sign in to comment.