As per method signature, $visitingUser is nullable, so we can't be sure calling getUid() on it will
work.
Closes #35766
Signed-off-by: Thomas Citharel <tcit@tcit.fr>
return;
}
if (!$this->appManager->isEnabledForUser($action->getAppId(), $visitingUser)) {
- $this->logger->notice('App: ' . $action->getAppId() . ' cannot register actions as it is not enabled for the visiting user: ' . $visitingUser->getUID());
+ $this->logger->notice('App: ' . $action->getAppId() . ' cannot register actions as it is not enabled for the visiting user: ' . ($visitingUser ? $visitingUser->getUID() : '(user not connected)'));
return;
}
}