if (!isset($runOnce)) {
$runOnce = TRUE;
- return TRUE;
}
-
- $root = rtrim($this->cmsRootPath(), '/' . DIRECTORY_SEPARATOR);
- if (empty($root) || !is_dir($root) || !chdir($root)) {
- return FALSE;
+ else {
+ return TRUE;
}
- require_once $root . '/../vendor/autoload.php'; /* assumes $root to be the _web_ root path, not the project root path. */
+ global $civicrm_paths;
+ require_once $civicrm_paths['civicrm.vendor']['path'] . '/autoload.php';
// seems like we've bootstrapped drupal
$config = CRM_Core_Config::singleton();
// if given username we expect a correct password.
$user = $security->loadUserByName($params['name']);
if ($user) {
- if (!$security->checkPassword($params['pass'], $user['password'] ?? '')) {
+ if (!$security->checkPassword($params['pass'], $user['hashed_password'] ?? '')) {
return FALSE;
}
}