Skip to content
Snippets Groups Projects
Commit b3940733 authored by GitLab CI's avatar GitLab CI
Browse files

Merge branch 'develop' into 'main'

Merging develop into main

See merge request !365
parents 709a01be d44555ae
No related branches found
Tags v3.2.229
1 merge request!365Merging develop into main
Pipeline #1364600 passed
......@@ -149,9 +149,6 @@
"drupal/menu_block": {
"#3082445 Add option to always render parent menu item": "https://www.drupal.org/files/issues/2020-10-12/menu_block-render-parent-3082445-26.patch"
},
"drupal/name": {
"#3478278 Name and IEF": "https://gitlab.lakedrops.com/composer/plugin/drupal-environment/-/raw/main/patches/d10/3478278.diff"
},
"drupal/pdfpreview": {
"#local debug": "https://gitlab.lakedrops.com/composer/plugin/drupal-environment/-/raw/main/patches/pdfpreview-debug.diff"
},
......
......@@ -149,9 +149,6 @@
"drupal/menu_block": {
"#3082445 Add option to always render parent menu item": "https://www.drupal.org/files/issues/2020-10-12/menu_block-render-parent-3082445-26.patch"
},
"drupal/name": {
"#3478278 Name and IEF": "https://gitlab.lakedrops.com/composer/plugin/drupal-environment/-/raw/main/patches/d10/3478278.diff"
},
"drupal/pdfpreview": {
"#local debug": "https://gitlab.lakedrops.com/composer/plugin/drupal-environment/-/raw/main/patches/pdfpreview-debug.diff"
},
......
diff --git a/name.module b/name.module
index 25b1d1149d96d9597ca6f42a9edb42f3d03ea4a3..866af4d5aaa14d430b9a67bc4a9fb65112776360 100644
--- a/name.module
+++ b/name.module
@@ -144,7 +144,8 @@ function name_user_format_name_alter_preload($account) {
$field_name = Drupal::config('name.settings')->get('user_preferred');
if ($field_name && FieldConfig::loadByName('user', 'user', $field_name)) {
$in_preload = TRUE;
- $account = User::load($account->id());
+ $id = $account->id();
+ $account = $id ? User::load($id) : 'unknown';
$in_preload = FALSE;
}
}
......@@ -146,9 +146,6 @@
"drupal/menu_block": {
"#3082445 Add option to always render parent menu item": "https://www.drupal.org/files/issues/2020-10-12/menu_block-render-parent-3082445-26.patch"
},
"drupal/name": {
"#3478278 Name and IEF": "https://gitlab.lakedrops.com/composer/plugin/drupal-environment/-/raw/main/patches/d10/3478278.diff"
},
"drupal/pdfpreview": {
"#local debug": "https://gitlab.lakedrops.com/composer/plugin/drupal-environment/-/raw/main/patches/pdfpreview-debug.diff"
},
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment