added bean property check
parent
b1c89783ff
commit
ecf99f960a
|
@ -10,6 +10,7 @@ import javax.servlet.http.HttpServletRequest;
|
|||
import org.apache.http.client.utils.URIBuilder;
|
||||
import org.mitre.openid.connect.client.model.IssuerServiceResponse;
|
||||
import org.mitre.openid.connect.client.service.IssuerService;
|
||||
import org.springframework.beans.factory.InitializingBean;
|
||||
import org.springframework.security.authentication.AuthenticationServiceException;
|
||||
|
||||
import com.google.common.base.Strings;
|
||||
|
@ -21,7 +22,7 @@ import com.google.common.base.Strings;
|
|||
* @author jricher
|
||||
*
|
||||
*/
|
||||
public class ThirdPartyIssuerService implements IssuerService {
|
||||
public class ThirdPartyIssuerService implements IssuerService, InitializingBean {
|
||||
|
||||
private String accountChooserUrl;
|
||||
|
||||
|
@ -68,4 +69,15 @@ public class ThirdPartyIssuerService implements IssuerService {
|
|||
this.accountChooserUrl = accountChooserUrl;
|
||||
}
|
||||
|
||||
/* (non-Javadoc)
|
||||
* @see org.springframework.beans.factory.InitializingBean#afterPropertiesSet()
|
||||
*/
|
||||
@Override
|
||||
public void afterPropertiesSet() throws Exception {
|
||||
if (Strings.isNullOrEmpty(this.accountChooserUrl)) {
|
||||
throw new IllegalArgumentException("Account Chooser URL cannot be null or empty");
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue