kopia lustrzana https://github.com/nextcloud/social
Fix detection of webfinger endpoint with no 'resource' param
This is necessary to make the overview test pass. $subject was null so strpos was throwing an exception, probably since php8. Signed-off-by: Louis Chemineau <louis@chmn.me>pull/1562/head
rodzic
f945d5fe63
commit
9263ff099a
|
@ -101,7 +101,7 @@ class WebfingerHandler implements IHandler {
|
|||
* @return IResponse|null
|
||||
*/
|
||||
public function handleWebfinger(IRequestContext $context): ?IResponse {
|
||||
$subject = $context->getHttpRequest()->getParam('resource');
|
||||
$subject = $context->getHttpRequest()->getParam('resource') ?? '';
|
||||
if (strpos($subject, 'acct:') === 0) {
|
||||
$subject = substr($subject, 5);
|
||||
}
|
||||
|
|
Ładowanie…
Reference in New Issue