accept profile URL as a LRDD identifier

This commit is contained in:
Evan Prodromou 2010-10-14 11:07:37 -04:00
parent 23ac961624
commit ecb582e419

View File

@ -46,7 +46,15 @@ class UserxrdAction extends XrdAction
} }
} else { } else {
$this->user = User::staticGet('uri', $this->uri); $this->user = User::staticGet('uri', $this->uri);
if (empty($this->user)) {
// try and get it by profile url
$profile = Profile::staticGet('profileurl', $this->uri);
if (!empty($profile)) {
$this->user = User::staticGet('id', $profile->id);
}
}
} }
if (!$this->user) { if (!$this->user) {
$this->clientError(_m('No such user.'), 404); $this->clientError(_m('No such user.'), 404);
return false; return false;