From 3aa256ec021d7351fd07b472a927a1b432d96799 Mon Sep 17 00:00:00 2001 From: Marcus Moore Date: Thu, 28 Sep 2023 12:33:20 -0700 Subject: [PATCH] Ensure non-checked out items can be displayed --- app/Models/Labels/FieldOption.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/Models/Labels/FieldOption.php b/app/Models/Labels/FieldOption.php index 2f874ec389..7e45cc0ce7 100644 --- a/app/Models/Labels/FieldOption.php +++ b/app/Models/Labels/FieldOption.php @@ -19,7 +19,7 @@ class FieldOption { // we want to avoid returning the property directly // and instead return the entity's presented name. if ($dataPath[0] === 'assignedTo'){ - return $asset->assignedTo->present()->fullName(); + return $asset->assignedTo ? $asset->assignedTo->present()->fullName() : null; } return $dataPath->reduce(function ($myValue, $path) {