Skip to content
Snippets Groups Projects
Commit 766b7691 authored by Angie Byron's avatar Angie Byron
Browse files

#779494 follow-up by marcingy, tobiasb, aspilicious: Fixed Notices on install screens.

parent 90f598d5
No related branches found
No related tags found
2 merge requests!7452Issue #1797438. HTML5 validation is preventing form submit and not fully...,!789Issue #3210310: Adjust Database API to remove deprecated Drupal 9 code in Drupal 10
......@@ -2105,8 +2105,10 @@ function _template_preprocess_default_variables() {
'logged_in' => FALSE,
);
// The user object has no uid property when the database does not exist.
if (isset($user->uid)) {
// The user object has no uid property when the database does not exist during
// install. The user_access() check deals with issues when in maintenance mode
// as uid is set but the user.module has not been included.
if (isset($user->uid) && function_exists('user_access')) {
$variables['is_admin'] = user_access('access administration pages');
$variables['logged_in'] = ($user->uid > 0);
}
......
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