From 0c6fe78a73fddf73145befa63161e58ce29263c2 Mon Sep 17 00:00:00 2001 From: Mikael Nordfeldth Date: Sat, 3 Oct 2015 00:43:34 +0200 Subject: [PATCH] Shorthand function for getActor --- plugins/Favorite/classes/Fave.php | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/plugins/Favorite/classes/Fave.php b/plugins/Favorite/classes/Fave.php index f40efcf8ab..1e011decf8 100644 --- a/plugins/Favorite/classes/Fave.php +++ b/plugins/Favorite/classes/Fave.php @@ -423,12 +423,7 @@ class Fave extends Managed_DataObject public function getActor() { - $profile = new Profile(); - $profile->id = $this->user_id; - if (!$profile->find(true)) { - throw new NoResultException($profile); - } - return $profile; + return Profile::getByID($this->user_id); } public function getActorObject() -- 2.39.5