Skip to content

Commit 301dfd1

Browse files
committed
Removed CORS headers from DistributeDataApiController
1 parent e043cec commit 301dfd1

File tree

1 file changed

+0
-6
lines changed

1 file changed

+0
-6
lines changed

api/src/main/java/edu/cornell/library/scholars/webapp/controller/api/DistributeDataApiController.java

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,6 @@ protected void doGet(HttpServletRequest req, HttpServletResponse resp) throws Se
5353

5454
String uri = findDistributorForAction(req, model);
5555
DataDistributor instance = instantiateDistributor(req, uri, model);
56-
setCorsHeaders(req, resp);
5756
runIt(req, resp, instance);
5857
} catch (NoSuchActionException e) {
5958
do400BadRequest(e.getMessage(), resp);
@@ -128,11 +127,6 @@ private void runIt(HttpServletRequest req, HttpServletResponse resp, DataDistrib
128127
}
129128
}
130129

131-
private void setCorsHeaders(HttpServletRequest req, HttpServletResponse resp) {
132-
log.debug("Setting CORS header for every request.");
133-
resp.setHeader("Access-Control-Allow-Origin", "*");
134-
}
135-
136130
private void do400BadRequest(String message, HttpServletResponse resp) throws IOException {
137131
log.debug("400BadRequest: " + message);
138132
resp.setStatus(400);

0 commit comments

Comments
 (0)