Bad parameter fixed

This commit is contained in:
Diogo Cordeiro 2018-08-02 03:55:15 +01:00
parent 8e80fb3528
commit c8f3f079cc
2 changed files with 4 additions and 4 deletions

View File

@ -139,8 +139,8 @@ class ActivityPubPlugin extends Plugin
}
try {
return Activitypub_notice::create_notice(
ActivityPub_explorer::get_profile_from_url($res->attributedTo),
$res->id,
ActivityPub_explorer::get_profile_from_url($res->attributedTo),
$res->id,
$res->url,
$res->content,
$res->cc,

View File

@ -201,11 +201,11 @@ class Activitypub_notice extends Managed_DataObject
* Validates a remote notice.
*
* @author Diogo Cordeiro <diogo@fc.up.pt>
* @param Array $data
* @param StdClass $data
* @return boolean true in case of success
* @throws Exception
*/
public static function validate_remote_notice($data)
public static function validate_remote_notice(&$data)
{
if (!isset($data->attributedTo)) {
common_debug('ActivityPub Notice Validator: Rejected because attributedTo was not specified.');