summaryrefslogtreecommitdiff
path: root/plugins/OStatus/actions
diff options
context:
space:
mode:
authorBrion Vibber <brion@pobox.com>2010-03-22 12:37:45 -0700
committerBrion Vibber <brion@pobox.com>2010-03-22 12:37:45 -0700
commit26f49de0dd5673584e734152d2d3329b90eb6978 (patch)
tree2ba00544c77cc3bfe0cafb4fa8fe60ce73d31d79 /plugins/OStatus/actions
parentc85228eadc60b50ed6e7c9cba596c3e66f5214b2 (diff)
parent27bfd1211d64298ee3c3b2d82d7b38ca1e1167ad (diff)
Merge branch 'testing' of git@gitorious.org:statusnet/mainline into 0.9.x
Conflicts: lib/attachmentlist.php
Diffstat (limited to 'plugins/OStatus/actions')
-rw-r--r--plugins/OStatus/actions/userxrd.php10
1 files changed, 7 insertions, 3 deletions
diff --git a/plugins/OStatus/actions/userxrd.php b/plugins/OStatus/actions/userxrd.php
index eb80a5ad4..6a6886eb8 100644
--- a/plugins/OStatus/actions/userxrd.php
+++ b/plugins/OStatus/actions/userxrd.php
@@ -35,9 +35,13 @@ class UserxrdAction extends XrdAction
$this->uri = Discovery::normalize($this->uri);
if (Discovery::isWebfinger($this->uri)) {
- list($nick, $domain) = explode('@', substr(urldecode($this->uri), 5));
- $nick = common_canonical_nickname($nick);
- $this->user = User::staticGet('nickname', $nick);
+ $parts = explode('@', substr(urldecode($this->uri), 5));
+ if (count($parts) == 2) {
+ list($nick, $domain) = $parts;
+ // @fixme confirm the domain too
+ $nick = common_canonical_nickname($nick);
+ $this->user = User::staticGet('nickname', $nick);
+ }
} else {
$this->user = User::staticGet('uri', $this->uri);
}