This is an automated email from the ASF dual-hosted git repository.

asf-gitbox-commits pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/openwebbeans.git

commit 8bd9b7ffc38a6eec293308146bf5f723706faa00
Author: Mark Struberg <[email protected]>
AuthorDate: Fri Jul 3 20:19:22 2026 +0200

    OWB-1463 we have far more normal classes than ParameterizedTypes
    
    Thus we change the path order to make it eject quicker.
---
 .../src/main/java/org/apache/webbeans/util/ClassUtil.java      | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git 
a/webbeans-impl/src/main/java/org/apache/webbeans/util/ClassUtil.java 
b/webbeans-impl/src/main/java/org/apache/webbeans/util/ClassUtil.java
index 3ff2bf0e5..1b1e77ad0 100644
--- a/webbeans-impl/src/main/java/org/apache/webbeans/util/ClassUtil.java
+++ b/webbeans-impl/src/main/java/org/apache/webbeans/util/ClassUtil.java
@@ -839,14 +839,14 @@ public final class ClassUtil
      */
     public static Class<?> getClazz(Type type)
     {
-        if(type instanceof ParameterizedType)
+        if(type instanceof Class)
         {
-            ParameterizedType pt = (ParameterizedType)type;
-            return (Class<?>)pt.getRawType();                
+            return (Class<?>)type;
         }
-        else if(type instanceof Class)
+        else if(type instanceof ParameterizedType)
         {
-            return (Class<?>)type;
+            ParameterizedType pt = (ParameterizedType)type;
+            return (Class<?>)pt.getRawType();                
         }
         else if(type instanceof GenericArrayType)
         {

Reply via email to