We are no longer offering accounts on this server. Consider https://gitlab.freedesktop.org/ as a place to host projects.

Commit 7be46410 authored by mattl's avatar mattl

Actually return an Ostatus_profile

parent 4790db34
...@@ -80,12 +80,13 @@ class Ostatus_profile extends Managed_DataObject ...@@ -80,12 +80,13 @@ class Ostatus_profile extends Managed_DataObject
return $this->uri; return $this->uri;
} }
public function fromProfile(Profile $profile) static function fromProfile(Profile $profile)
{ {
$oprofile = Ostatus_profile::getKV('profile_id', $profile->id); $oprofile = Ostatus_profile::getKV('profile_id', $profile->getID());
if (!$oprofile instanceof Ostatus_profile) { if (!$oprofile instanceof Ostatus_profile) {
throw new Exception('No Ostatus_profile for Profile ID: '.$profile->id); throw new Exception('No Ostatus_profile for Profile ID: '.$profile->getID());
} }
return $oprofile;
} }
/** /**
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment