aboutsummaryrefslogtreecommitdiffstats
path: root/Zotlabs/Lib/ActivityStreams.php
diff options
context:
space:
mode:
Diffstat (limited to 'Zotlabs/Lib/ActivityStreams.php')
-rw-r--r--Zotlabs/Lib/ActivityStreams.php5
1 files changed, 4 insertions, 1 deletions
diff --git a/Zotlabs/Lib/ActivityStreams.php b/Zotlabs/Lib/ActivityStreams.php
index 2e9bb0703..37e717f58 100644
--- a/Zotlabs/Lib/ActivityStreams.php
+++ b/Zotlabs/Lib/ActivityStreams.php
@@ -9,6 +9,7 @@ namespace Zotlabs\Lib;
*/
class ActivityStreams {
+ public $raw = null;
public $data;
public $valid = false;
public $id = '';
@@ -33,7 +34,9 @@ class ActivityStreams {
*/
function __construct($string) {
+ $this->raw = $string;
$this->data = json_decode($string, true);
+
if($this->data) {
$this->valid = true;
}
@@ -204,7 +207,7 @@ class ActivityStreams {
}
$x = z_fetch_url($url, true, $redirects,
- ['headers' => [ 'Accept: application/ld+json; profile="https://www.w3.org/ns/activitystreams", application/activity+json' ]]);
+ ['headers' => [ 'Accept: application/activity+json, application/ld+json; profile="https://www.w3.org/ns/activitystreams"' ]]);
if($x['success'])
return json_decode($x['body'], true);