protected function FacebookAuth::validateConfig in Social Auth Facebook 8
Same name and namespace in other branches
- 8.2 src/Plugin/Network/FacebookAuth.php \Drupal\social_auth_facebook\Plugin\Network\FacebookAuth::validateConfig()
- 3.x src/Plugin/Network/FacebookAuth.php \Drupal\social_auth_facebook\Plugin\Network\FacebookAuth::validateConfig()
Checks that module is configured.
Parameters
\Drupal\social_auth_facebook\Settings\FacebookAuthSettings $settings: The Facebook auth settings.
Return value
bool True if module is configured. False otherwise.
1 call to FacebookAuth::validateConfig()
- FacebookAuth::initSdk in src/
Plugin/ Network/ FacebookAuth.php - Sets the underlying SDK library.
File
- src/
Plugin/ Network/ FacebookAuth.php, line 139
Class
- FacebookAuth
- Defines a Network Plugin for Social Auth Facebook.
Namespace
Drupal\social_auth_facebook\Plugin\NetworkCode
protected function validateConfig(FacebookAuthSettings $settings) {
$app_id = $settings
->getAppId();
$app_secret = $settings
->getAppSecret();
$graph_version = $settings
->getGraphVersion();
if (!$app_id || !$app_secret || !$graph_version) {
$this->loggerFactory
->get('social_auth_facebook')
->error('Define App ID and App Secret on module settings.');
return FALSE;
}
return TRUE;
}