diff --git a/common/src/main/java/com/jeesite/common/lang/ExceptionUtils.java b/common/src/main/java/com/jeesite/common/lang/ExceptionUtils.java index 3330c994..7c6e5622 100644 --- a/common/src/main/java/com/jeesite/common/lang/ExceptionUtils.java +++ b/common/src/main/java/com/jeesite/common/lang/ExceptionUtils.java @@ -5,11 +5,11 @@ */ package com.jeesite.common.lang; +import jakarta.servlet.http.HttpServletRequest; + import java.io.PrintWriter; import java.io.StringWriter; -import jakarta.servlet.http.HttpServletRequest; - /** * 关于异常的工具类. * @author calvin @@ -26,8 +26,8 @@ public class ExceptionUtils { Throwable ex = null; if (request.getAttribute("exception") != null) { ex = (Throwable) request.getAttribute("exception"); - } else if (request.getAttribute("javax.servlet.error.exception") != null) { - ex = (Throwable) request.getAttribute("javax.servlet.error.exception"); + } else if (request.getAttribute("jakarta.servlet.error.exception") != null) { + ex = (Throwable) request.getAttribute("jakarta.servlet.error.exception"); } return ex; }