Refactors Apache CXF JAXRS implementation
This commit is contained in:
parent
f2bbe6341f
commit
131b695268
@ -61,13 +61,11 @@ public class Course {
|
|||||||
@Path("{studentOrder}")
|
@Path("{studentOrder}")
|
||||||
public Response deleteStudent(@PathParam("studentOrder") int studentOrder) {
|
public Response deleteStudent(@PathParam("studentOrder") int studentOrder) {
|
||||||
Student student = students.get(studentOrder);
|
Student student = students.get(studentOrder);
|
||||||
Response response;
|
|
||||||
if (student != null) {
|
if (student != null) {
|
||||||
students.remove(studentOrder);
|
students.remove(studentOrder);
|
||||||
response = Response.ok().build();
|
return Response.ok().build();
|
||||||
} else {
|
} else {
|
||||||
response = Response.notModified().build();
|
return Response.notModified().build();
|
||||||
}
|
}
|
||||||
return response;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
Loading…
x
Reference in New Issue
Block a user