You are here

protected function SimpleFbConnectFbFactory::validateConfig in Simple FB Connect 8.3

Checks that module is configured.

Return value

bool True if module is configured False otherwise

1 call to SimpleFbConnectFbFactory::validateConfig()
SimpleFbConnectFbFactory::getFbService in src/SimpleFbConnectFbFactory.php
Returns an instance of Facebook\Facebook service.

File

src/SimpleFbConnectFbFactory.php, line 79

Class

SimpleFbConnectFbFactory
Class SimpleFbConnectFbFactory.

Namespace

Drupal\simple_fb_connect

Code

protected function validateConfig() {
  $app_id = $this
    ->getAppId();
  $app_secret = $this
    ->getAppSecret();
  if (!$app_id || !$app_secret) {
    $this->loggerFactory
      ->get('simple_fb_connect')
      ->error('Define App ID and App Secret on module settings.');
    return FALSE;
  }
  return TRUE;
}