Merge branch 'fix-webfinger-link-header' into 'master'

Add all link headers, not just the last one

Given the way Link headers work, it does not make any sense to
just replace all other ones.  Especially when we ourselves are adding
in a loop.

See merge request !47
This commit is contained in:
mmn 2015-11-05 15:12:10 +00:00
commit 959f971a65

View File

@ -148,7 +148,7 @@ class WebFingerPlugin extends Plugin
$url = common_local_url('webfinger') . '?resource='.$acct;
foreach (array(Discovery::JRD_MIMETYPE, Discovery::XRD_MIMETYPE) as $type) {
header('Link: <'.$url.'>; rel="'. Discovery::LRDD_REL.'"; type="'.$type.'"');
header('Link: <'.$url.'>; rel="'. Discovery::LRDD_REL.'"; type="'.$type.'"', false);
}
}
}