Skip to content
This repository has been archived by the owner on Nov 9, 2017. It is now read-only.

Commit

Permalink
fix the NullPointerException
Browse files Browse the repository at this point in the history
  • Loading branch information
hding committed May 5, 2011
1 parent 319d133 commit 883ad8c
Showing 1 changed file with 4 additions and 2 deletions.
Expand Up @@ -29,6 +29,8 @@
import javax.faces.context.FacesContext;


import org.jboss.seam.Component;
import org.jboss.seam.ScopeType;
import org.jboss.seam.annotations.Install;
import org.jboss.seam.annotations.Name;
import org.jboss.seam.annotations.Scope;
Expand All @@ -52,12 +54,12 @@ public class SpNegoIdentity implements Serializable
private static final String SUBJECT = "subject";
private static final String PRINCIPAL = "principal";
private static final LogProvider log = Logging.getLogProvider(SpNegoIdentity.class);
private ZanataIdentity identity;

public void setCredential()
{
try
{
ZanataIdentity identity = (ZanataIdentity) Component.getInstance(ZanataIdentity.class, ScopeType.SESSION);
if (identity.isLoggedIn())
{
if (Events.exists())
Expand Down Expand Up @@ -87,7 +89,7 @@ public void setCredential()
}
catch (Exception e)
{
log.info(e.getMessage());
log.warn(e.getMessage(), e);
}
}
}

0 comments on commit 883ad8c

Please sign in to comment.