Skip to content

Commit

Permalink
EXTCDI-304 improvement for openejb
Browse files Browse the repository at this point in the history
git-svn-id: https://svn.apache.org/repos/asf/myfaces/extensions/cdi/trunk@1423273 13f79535-47bb-0310-9956-ffa450edef68
  • Loading branch information
gpetracek committed Dec 18, 2012
1 parent 791def5 commit 7645eb2
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 0 deletions.
Expand Up @@ -93,6 +93,12 @@ public <T> T get(Contextual<T> component, CreationalContext<T> creationalContext
*/
public <T> T get(Contextual<T> component)
{
//workaround for openejb - see EXTCDI-304
if (component == null)
{
return null;
}

if (component instanceof Bean)
{
return this.conversationContext.resolve((Bean<T>)component);
Expand Down
Expand Up @@ -56,6 +56,12 @@ public class ViewScopedContext implements Context, SystemEventListener
*/
public <T> T get(Contextual<T> component)
{
//workaround for openejb - see EXTCDI-304
if (component == null)
{
return null;
}

checkActive();

if(!isJsfSubscribed)
Expand Down

0 comments on commit 7645eb2

Please sign in to comment.