From af6c37ec59123bdb0d3042004ac0c802e1c29d75 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=BC=80=E6=BA=90=E6=B5=B7=E5=93=A5?= Date: Sat, 6 May 2023 15:30:58 +0800 Subject: [PATCH] =?UTF-8?q?fixed=EF=BC=9A=E4=B8=8D=E6=94=AF=E6=8C=81?= =?UTF-8?q?=E8=87=AA=E5=B7=B1=E6=89=A9=E5=B1=95=20mapper=20=E7=9A=84?= =?UTF-8?q?=E9=97=AE=E9=A2=98=EF=BC=9Bclose=20#I6ZTS3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../main/java/com/mybatisflex/core/table/TableInfoFactory.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/mybatis-flex-core/src/main/java/com/mybatisflex/core/table/TableInfoFactory.java b/mybatis-flex-core/src/main/java/com/mybatisflex/core/table/TableInfoFactory.java index 31277e67..9885b723 100644 --- a/mybatis-flex-core/src/main/java/com/mybatisflex/core/table/TableInfoFactory.java +++ b/mybatis-flex-core/src/main/java/com/mybatisflex/core/table/TableInfoFactory.java @@ -101,7 +101,8 @@ public class TableInfoFactory { if (genericInterfaces.length == 1) { Type type = genericInterfaces[0]; if (type instanceof ParameterizedType) { - return (Class) ((ParameterizedType) type).getActualTypeArguments()[0]; + Type actualTypeArgument = ((ParameterizedType) type).getActualTypeArguments()[0]; + return actualTypeArgument instanceof Class ? (Class) actualTypeArgument : null; } else if (type instanceof Class) { return getEntityClass((Class) type); }