back to wrestling with the !@#$ diaspora recursive reshare from hell
This commit is contained in:
parent
5362943330
commit
65b84e839a
@ -927,9 +927,14 @@ function get_diaspora_reshare_xml($url,$recurse = 0) {
|
||||
|
||||
// see if it's a reshare of a reshare
|
||||
|
||||
if($source_xml->root_diaspora_id && $source_xml->root_guid && $recurse < 15) {
|
||||
$orig_author = notags(unxmlify($source_xml->root_diaspora_id));
|
||||
$orig_guid = notags(unxmlify($source_xml->root_guid));
|
||||
if($source_xml->post->reshare)
|
||||
$xml = $source_xml->post->reshare;
|
||||
else
|
||||
return false;
|
||||
|
||||
if($xml->root_diaspora_id && $xml->root_guid && $recurse < 15) {
|
||||
$orig_author = notags(unxmlify($xml->root_diaspora_id));
|
||||
$orig_guid = notags(unxmlify($xml->root_guid));
|
||||
$source_url = 'https://' . substr($orig_author,strpos($orig_author,'@')+1) . '/p/' . $orig_guid . '.xml';
|
||||
$y = get_diaspora_reshare_xml($source_url,$recurse+1);
|
||||
if($y)
|
||||
|
Reference in New Issue
Block a user