function DrupalFinder::getDrupalRoot
Get the Drupal root.
Return value
string|bool The path to the Drupal root, if it was discovered. False otherwise.
2 calls to DrupalFinder::getDrupalRoot()
- DrupalFinder::allPathsKnown in vendor/
webflo/ drupal-finder/ src/ DrupalFinder.php - Helper function to quickly determine whether or not all paths are known.
- DrupalFinder::locateRoot in vendor/
webflo/ drupal-finder/ src/ DrupalFinder.php - Locate Drupal, Composer, and vendor directory paths.
File
-
vendor/
webflo/ drupal-finder/ src/ DrupalFinder.php, line 106
Class
Namespace
DrupalFinderCode
public function getDrupalRoot() {
$environment_path = $this->getValidEnvironmentVariablePath(self::ENV_DRUPAL_ROOT);
return !empty($environment_path) ? $environment_path : $this->drupalRoot;
}