Skip to content

Commit 3d643f1

Browse files
committed
Fix EntityController@show due to ldaprecord changes
1 parent 8955edf commit 3d643f1

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

app/Http/Controllers/EntityController.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -175,7 +175,7 @@ public function show(Entity $entity)
175175
if (! app()->environment('testing')) {
176176
if ($entity->type->value === 'idp' && ! $entity->hfd) {
177177
$eduidczOrganization = EduidczOrganization::whereEntityIDofIdP($entity->entityid)->first();
178-
$cesnetOrganization = CesnetOrganization::find($eduidczOrganization?->getFirstAttribute('oPointer'));
178+
$cesnetOrganization = $eduidczOrganization ? CesnetOrganization::find($eduidczOrganization?->getFirstAttribute('oPointer')) : null;
179179
$cesnetOrganizations = is_null($cesnetOrganization) ? CesnetOrganization::select('o')->get() : null;
180180
}
181181
}

0 commit comments

Comments
 (0)