Skip to content

Commit

Permalink
fix: Remove doubled api string in location header [DHIS2-12536] (#19307)
Browse files Browse the repository at this point in the history
  • Loading branch information
enricocolasante authored Nov 27, 2024
1 parent 9b6a726 commit 2c59ece
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -233,7 +233,7 @@ public WebMessage postEnrollmentJson(
if (!importSummary.getStatus().equals(ImportStatus.ERROR)) {
importSummaries(importSummaries)
.setHttpStatus(HttpStatus.CREATED)
.setLocation("/api/" + "enrollments" + "/" + importSummary.getReference());
.setLocation("enrollments/" + importSummary.getReference());
}
}

Expand Down Expand Up @@ -280,7 +280,7 @@ public WebMessage postEnrollmentXml(
if (!importSummary.getStatus().equals(ImportStatus.ERROR)) {
importSummaries(importSummaries)
.setHttpStatus(HttpStatus.CREATED)
.setLocation("/api/" + "enrollments" + "/" + importSummary.getReference());
.setLocation("enrollments/" + importSummary.getReference());
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -450,7 +450,7 @@ private WebMessage postTrackedEntityInstance(
.setLocation(
singleSummary == null
? null
: "/api/" + "trackedEntityInstances" + "/" + singleSummary.getReference());
: "trackedEntityInstances/" + singleSummary.getReference());
}
return jobConfigurationReport(jobId).setLocation("/system/tasks/" + TEI_IMPORT);
}
Expand Down

0 comments on commit 2c59ece

Please sign in to comment.