fixed paths in ApiEndpoint
Signed-off-by: Stephan Richter <s.richter@srsoftware.de>
This commit is contained in:
@@ -89,7 +89,7 @@ public class ApiEndpoint extends PathHandler {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean doDelete(Path path, HttpExchange ex) throws IOException {
|
public boolean doDelete(Path path, HttpExchange ex) throws IOException {
|
||||||
if (path.equals("/event")) return sendContent(ex, delete(path, ex));
|
if (path.equals("event")) return sendContent(ex, delete(path, ex));
|
||||||
return unknownPath(ex, path);
|
return unknownPath(ex, path);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -114,13 +114,13 @@ public class ApiEndpoint extends PathHandler {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean doPatch(Path path, HttpExchange ex) throws IOException {
|
public boolean doPatch(Path path, HttpExchange ex) throws IOException {
|
||||||
if (path.equals("/event")) return sendContent(ex, updateEvent(ex));
|
if (path.equals("event")) return sendContent(ex, updateEvent(ex));
|
||||||
return unknownPath(ex, path);
|
return unknownPath(ex, path);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean doPost(Path path, HttpExchange ex) throws IOException {
|
public boolean doPost(Path path, HttpExchange ex) throws IOException {
|
||||||
if (path.equals("/event")) return sendContent(ex, createEvent(ex));
|
if (path.equals("event")) return sendContent(ex, createEvent(ex));
|
||||||
return unknownPath(ex, path);
|
return unknownPath(ex, path);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user