@Override protected void internalInit(final WebContext context) { super.internalInit(context); CommonHelper.assertNotBlank("fields", this.fields); this.api20 = new ExtendedFacebookApi(); if (StringUtils.isNotBlank(this.scope)) { this.service = new StateOAuth20ServiceImpl( this.api20, new OAuthConfig( this.key, this.secret, computeFinalCallbackUrl(context), SignatureType.Header, this.scope, null), this.connectTimeout, this.readTimeout, this.proxyHost, this.proxyPort); } else { this.service = new StateOAuth20ServiceImpl( this.api20, new OAuthConfig( this.key, this.secret, computeFinalCallbackUrl(context), SignatureType.Header, null, null), this.connectTimeout, this.readTimeout, this.proxyHost, this.proxyPort); } }