added a location check, to prevent notif blowing up

This commit is contained in:
Godfrey M
2024-01-23 13:05:39 -08:00
parent b797795d37
commit f270672a3d
5 changed files with 24 additions and 17 deletions
@@ -116,7 +116,7 @@ class CheckoutAccessoryNotification extends Notification
->title("Accessory Checked Out")
->addStartGroupToSection('activityText')
->fact(htmlspecialchars_decode($item->present()->name), '', 'activityTitle')
->fact('Checked out from ', $item->location->name)
->fact('Checked out from ', $item->location->name ? $item->location->name : '')
->fact(trans('mail.Accessory_Checkout_Notification')." by ", $admin->present()->fullName())
->fact('Number Remaining', $item->numRemaining())
->fact('Notes', $note ?: 'No notes');