Fixes #10338 - ErorrHandler#writeErrorJson is private

Made the writeErrorXYZ() methods protected in ErrorHandler for core, ee9 and ee10.

Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
This commit is contained in:
Simone Bordet 2023-08-23 15:58:01 +02:00
parent 04b53f3f15
commit 9d908839cf
3 changed files with 5 additions and 5 deletions

View File

@ -368,7 +368,7 @@ public class ErrorHandler implements Request.Handler
}
}
private void writeErrorJson(Request request, PrintWriter writer, int code, String message, Throwable cause, boolean showStacks)
protected void writeErrorJson(Request request, PrintWriter writer, int code, String message, Throwable cause, boolean showStacks)
{
Map<String, String> json = new HashMap<>();

View File

@ -439,7 +439,7 @@ public class ErrorHandler implements Request.Handler
writer.write("</td></tr>\n");
}
private void writeErrorPlain(HttpServletRequest request, PrintWriter writer, int code, String message)
protected void writeErrorPlain(HttpServletRequest request, PrintWriter writer, int code, String message)
{
writer.write("HTTP ERROR ");
writer.write(Integer.toString(code));
@ -465,7 +465,7 @@ public class ErrorHandler implements Request.Handler
}
}
private void writeErrorJson(HttpServletRequest request, PrintWriter writer, int code, String message)
protected void writeErrorJson(HttpServletRequest request, PrintWriter writer, int code, String message)
{
Throwable cause = (Throwable)request.getAttribute(Dispatcher.ERROR_EXCEPTION);
Object servlet = request.getAttribute(Dispatcher.ERROR_SERVLET_NAME);

View File

@ -432,7 +432,7 @@ public class ErrorHandler extends AbstractHandler
writer.write("</td></tr>\n");
}
private void writeErrorPlain(HttpServletRequest request, PrintWriter writer, int code, String message)
protected void writeErrorPlain(HttpServletRequest request, PrintWriter writer, int code, String message)
{
writer.write("HTTP ERROR ");
writer.write(Integer.toString(code));
@ -458,7 +458,7 @@ public class ErrorHandler extends AbstractHandler
}
}
private void writeErrorJson(HttpServletRequest request, PrintWriter writer, int code, String message)
protected void writeErrorJson(HttpServletRequest request, PrintWriter writer, int code, String message)
{
Throwable cause = (Throwable)request.getAttribute(Dispatcher.ERROR_EXCEPTION);
Object servlet = request.getAttribute(Dispatcher.ERROR_SERVLET_NAME);