projects
/
civicrm-core.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
4a801f7
)
dev/drupal#19 Drupal8: fix bootstrap when used by the REST API
author
Mathieu Lutfy
<mathieu@symbiotic.coop>
Wed, 22 May 2019 23:59:28 +0000
(19:59 -0400)
committer
Mathieu Lutfy
<mathieu@bidon.ca>
Wed, 22 May 2019 23:59:28 +0000
(19:59 -0400)
CRM/Utils/System/Drupal8.php
patch
|
blob
|
blame
|
history
diff --git
a/CRM/Utils/System/Drupal8.php
b/CRM/Utils/System/Drupal8.php
index f1df28970aeec08e8e2f5cabb2130f62497356f1..b832eee6825c683b00b93aa53ce91dca7b3807d8 100644
(file)
--- a/
CRM/Utils/System/Drupal8.php
+++ b/
CRM/Utils/System/Drupal8.php
@@
-659,7
+659,7
@@
class CRM_Utils_System_Drupal8 extends CRM_Utils_System_DrupalBase {
*/
public function getCurrentLanguage() {
// Drupal might not be bootstrapped if being called by the REST API.
- if (!class_exists('Drupal')) {
+ if (!class_exists('Drupal')
|| !\Drupal::hasContainer()
) {
return NULL;
}
@@
-706,7
+706,7
@@
class CRM_Utils_System_Drupal8 extends CRM_Utils_System_DrupalBase {
}
// Drupal might not be bootstrapped if being called by the REST API.
- if (!class_exists('Drupal')) {
+ if (!class_exists('Drupal')
|| !\Drupal::hasContainer()
) {
return NULL;
}