Skip to content

Commit

Permalink
Trivial to check for a proxy without refering to core (make Porting p…
Browse files Browse the repository at this point in the history
…ackage less dependent on core code)
  • Loading branch information
pmuir committed Dec 2, 2009
1 parent 1eb9048 commit d66fc55
Showing 1 changed file with 1 addition and 2 deletions.
@@ -1,7 +1,6 @@
package org.jboss.weld.tck;

import org.jboss.jsr299.tck.spi.Beans;
import org.jboss.weld.util.Proxies;

/**
* Implements the Beans SPI for the TCK specifically for the JBoss RI.
Expand All @@ -16,7 +15,7 @@ public class BeansImpl implements Beans

public boolean isProxy(Object instance)
{
return Proxies.isProxy(instance);
return instance.getClass().getName().indexOf("_$$_javassist_") > 0;
}

}

0 comments on commit d66fc55

Please sign in to comment.