ensureActivityObjectProfile is more thorough than createAct...

This commit is contained in:
Mikael Nordfeldth 2015-01-12 11:47:21 +01:00
parent c7df5594d0
commit 66044b7782

View File

@ -255,7 +255,7 @@ class SalmonAction extends Action
if (!$profile instanceof Profile) { if (!$profile instanceof Profile) {
common_debug("We do not have a local profile to connect to this activity's author. Let's create one."); common_debug("We do not have a local profile to connect to this activity's author. Let's create one.");
// ensureActivityObjectProfile throws exception on failure // ensureActivityObjectProfile throws exception on failure
$oprofile = Ostatus_profile::createActivityObjectProfile($actor); $oprofile = Ostatus_profile::ensureActivityObjectProfile($actor);
$profile = $oprofile->localProfile(); $profile = $oprofile->localProfile();
} }
assert($profile instanceof Profile); assert($profile instanceof Profile);