From c32bb55b8a70d744f9400c519756334c3a4b0dba Mon Sep 17 00:00:00 2001 From: Daniel Supernault Date: Mon, 20 Jun 2022 21:48:37 -0600 Subject: [PATCH] Update AP helpers, fix last_fetched_at condition --- app/Util/ActivityPub/Helpers.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/Util/ActivityPub/Helpers.php b/app/Util/ActivityPub/Helpers.php index b72eeb32..b6fea3b2 100644 --- a/app/Util/ActivityPub/Helpers.php +++ b/app/Util/ActivityPub/Helpers.php @@ -695,7 +695,7 @@ class Helpers { } if($profile = Profile::whereRemoteUrl($url)->first()) { - if($profile->last_fetched_at->lt(now()->subHours(24))) { + if($profile->last_fetched_at && $profile->last_fetched_at->lt(now()->subHours(24))) { return self::profileUpdateOrCreate($url); } return $profile;