Return 404 on resource-not-found for WebFinger
This commit is contained in:
parent
d350a20e1f
commit
6d0ac21185
|
@ -40,15 +40,15 @@ class WebfingerAction extends XrdAction
|
||||||
Event::handle('EndGetWebFingerResource', array($this->resource, &$this->target, $this->args));
|
Event::handle('EndGetWebFingerResource', array($this->resource, &$this->target, $this->args));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (!$this->target instanceof WebFingerResource) {
|
||||||
|
throw new ServerException('Resource not found in local database.', 404);
|
||||||
|
}
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
protected function setXRD()
|
protected function setXRD()
|
||||||
{
|
{
|
||||||
if (!($this->target instanceof WebFingerResource)) {
|
|
||||||
throw new Exception(_('Target not set for resource descriptor'));
|
|
||||||
}
|
|
||||||
|
|
||||||
$this->xrd->subject = $this->resource;
|
$this->xrd->subject = $this->resource;
|
||||||
|
|
||||||
foreach ($this->target->getAliases() as $alias) {
|
foreach ($this->target->getAliases() as $alias) {
|
||||||
|
|
Loading…
Reference in New Issue
Block a user