diff --git a/modules/custom/az_person/src/AZUserToolbarLinkBuilder.php b/modules/custom/az_person/src/AZUserToolbarLinkBuilder.php index b9dcc87c0a..4fdbb0974e 100644 --- a/modules/custom/az_person/src/AZUserToolbarLinkBuilder.php +++ b/modules/custom/az_person/src/AZUserToolbarLinkBuilder.php @@ -68,13 +68,11 @@ public function __construct( public function renderToolbarLinks() { $build = parent::renderToolbarLinks(); $additional_links = []; - // Only valid if we have the externalauth module. if (!empty($this->authmap)) { // Check if we have permission. if ($this->account->hasPermission('edit matching netid content')) { $auth = $this->authmap->get($this->account->id(), 'cas'); - if (($auth !== FALSE)) { // Verify that 'field_az_netid' exists for 'az_person' content type. $field_definitions = $this->entityFieldManager->getFieldDefinitions('node', 'az_person'); @@ -85,7 +83,6 @@ public function renderToolbarLinks() { 'type' => 'az_person', 'status' => [1, TRUE], ]); - if (!empty($persons)) { $person = reset($persons); // If we have a linked az person, generate links.