diff --git a/src/org/redkale/source/EntityInfo.java b/src/org/redkale/source/EntityInfo.java index 447be4073..b427f4046 100644 --- a/src/org/redkale/source/EntityInfo.java +++ b/src/org/redkale/source/EntityInfo.java @@ -239,7 +239,7 @@ public final class EntityInfo { } //--------------------------------------------- Table t = type.getAnnotation(Table.class); - if (type.getAnnotation(VirtualEntity.class) != null || "memory".equalsIgnoreCase(source.getType())) { + if (type.getAnnotation(VirtualEntity.class) != null || (source == null || "memory".equalsIgnoreCase(source.getType()))) { this.table = null; BiFunction loader = null; try {