解决短链接响应错乱问题

This commit is contained in:
imhao183
2021-05-24 10:31:09 +08:00
parent 141c8f38d8
commit b0fe3fd57f
82 changed files with 264 additions and 244 deletions
@@ -27,7 +27,7 @@ public class NotFoundAction extends Action{
private final static String TEMPLATE_ERROR = "<!DOCTYPE html><html><head><title>LoServer - Error report</title><style>h1,h3 {color:white; background-color: gray;}</style></head><body><h1>HTTP Status {} - {}</h1><hr size=\"1\" noshade=\"noshade\" /><p>{}</p><hr size=\"1\" noshade=\"noshade\" /><h3>LoServer</h3></body></html>";
@Override
public boolean action(Request request) {
public boolean action(Request request, Response response) {
response.sendError(HttpResponseStatus.NOT_FOUND, "404 Not found!");
return true;
}