File tree Expand file tree Collapse file tree 1 file changed +3
-6
lines changed
spring-data-jpa/src/main/java/org/springframework/data/jpa/repository/query Expand file tree Collapse file tree 1 file changed +3
-6
lines changed Original file line number Diff line number Diff line change @@ -35,10 +35,7 @@ public final class QueryEnhancerFactory {
3535 private static final boolean jSqlParserPresent = ClassUtils .isPresent ("net.sf.jsqlparser.parser.JSqlParser" ,
3636 QueryEnhancerFactory .class .getClassLoader ());
3737
38- private static final boolean hibernatePresent = ClassUtils .isPresent ("org.hibernate.query.TypedParameterValue" ,
39- QueryEnhancerFactory .class .getClassLoader ());
40-
41- private static final boolean hibernate5Present = ClassUtils .isPresent ("org.hibernate.jpa.TypedParameterValue" ,
38+ private static final boolean hibernatePresent = ClassUtils .isPresent ("org.hibernate.Hibernate" ,
4239 QueryEnhancerFactory .class .getClassLoader ());
4340
4441 static {
@@ -47,7 +44,7 @@ public final class QueryEnhancerFactory {
4744 LOG .info ("JSqlParser is in classpath; If applicable, JSqlParser will be used" );
4845 }
4946
50- if (hibernatePresent || hibernate5Present ) {
47+ if (hibernatePresent ) {
5148 LOG .info ("Hibernate is in classpath; If applicable, HQL parser will be used." );
5249 }
5350 }
@@ -74,7 +71,7 @@ public static QueryEnhancer forQuery(DeclaredQuery query) {
7471 return new DefaultQueryEnhancer (query );
7572 }
7673
77- return ( hibernatePresent || hibernate5Present ) ? JpaQueryEnhancer .forHql (query ) : JpaQueryEnhancer .forJpql (query );
74+ return hibernatePresent ? JpaQueryEnhancer .forHql (query ) : JpaQueryEnhancer .forJpql (query );
7875 }
7976
8077}
You can’t perform that action at this time.
0 commit comments