Commit 92e2dafe authored by catch's avatar catch
Browse files

Issue #3205344 by alexpott: Calling system_requirements() can be expensive -...

Issue #3205344 by alexpott: Calling system_requirements() can be expensive - do the cheap check first
parent 6ee786e9
......@@ -118,7 +118,7 @@ public static function create(ContainerInterface $container) {
*/
public function overview($link_id) {
// Check for status report errors.
if ($this->systemManager->checkRequirements() && $this->currentUser()->hasPermission('administer site configuration')) {
if ($this->currentUser()->hasPermission('administer site configuration') && $this->systemManager->checkRequirements()) {
$this->messenger()->addError($this->t('One or more problems were detected with your Drupal installation. Check the <a href=":status">status report</a> for more information.', [':status' => Url::fromRoute('system.status')->toString()]));
}
// Load all menu links below it.
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment