You are here

private function SpiController::getUidZeroIsPresent in Acquia Connector 8

Same name and namespace in other branches
  1. 8.2 src/Controller/SpiController.php \Drupal\acquia_connector\Controller\SpiController::getUidZeroIsPresent()
  2. 3.x src/Controller/SpiController.php \Drupal\acquia_connector\Controller\SpiController::getUidZeroIsPresent()

Check the presence of UID 0 in the users table.

Return value

bool Whether UID 0 is present.

1 call to SpiController::getUidZeroIsPresent()
SpiController::get in src/Controller/SpiController.php
Gather site profile information about this site.

File

src/Controller/SpiController.php, line 651

Class

SpiController
SPI Controller class.

Namespace

Drupal\acquia_connector\Controller

Code

private function getUidZeroIsPresent() {
  $count = Database::getConnection()
    ->query('SELECT uid FROM {users} WHERE uid = 0')
    ->fetchAll();
  return (bool) $count;
}