From ed465091554b84c9863e39725ddf56b789d64669 Mon Sep 17 00:00:00 2001 From: anonymous puppy Date: Wed, 21 Jan 2026 19:49:18 +0000 Subject: Fix null warning in Actor follow --- Digitigrade/Model/Actor.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Digitigrade/Model/Actor.php') diff --git a/Digitigrade/Model/Actor.php b/Digitigrade/Model/Actor.php index a8909df..1db464d 100644 --- a/Digitigrade/Model/Actor.php +++ b/Digitigrade/Model/Actor.php @@ -199,7 +199,7 @@ class Actor extends PushableModel implements RpcReceiver { switch ($method) { case 'follow': $status = $this->requestToFollow ? FollowRelationStatus::PENDING : FollowRelationStatus::ACTIVE; - if (strlen(trim($result->body)) > 0) { // remote server returned new status, use that instead + if (isset($result->body) && strlen(trim($result->body)) > 0) { // remote server returned new status, use that instead $status = FollowRelationStatus::tryFrom(trim($result->body)) ?? $status; } $rel = FollowRelation::create($args[0], $this, $status); -- cgit v1.3