From 750d7577c8eadebcb16ea90a10472ee8f911f179 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Josip=20Crnkovi=C4=87?= Date: Mon, 2 Aug 2021 09:56:13 +0200 Subject: [PATCH] refactor: always load relatable model for notifications (#53) --- src/Models/Concerns/HasNotifications.php | 1 + 1 file changed, 1 insertion(+) diff --git a/src/Models/Concerns/HasNotifications.php b/src/Models/Concerns/HasNotifications.php index 30317e6..de8b21f 100644 --- a/src/Models/Concerns/HasNotifications.php +++ b/src/Models/Concerns/HasNotifications.php @@ -18,6 +18,7 @@ public function notifications(): MorphMany { return $this ->morphMany(config('hermes.models.notification'), 'notifiable') + ->with('relatable') ->orderBy('created_at', 'desc') ->orderBy('id'); }