diff options
Diffstat (limited to 'actions/twitapiusers.php')
-rw-r--r-- | actions/twitapiusers.php | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/actions/twitapiusers.php b/actions/twitapiusers.php index a47fdfbc3..fea41b397 100644 --- a/actions/twitapiusers.php +++ b/actions/twitapiusers.php @@ -1,7 +1,7 @@ <?php /* * Laconica - a distributed open-source microblogging tool - * Copyright (C) 2008, Controlez-Vous, Inc. + * Copyright (C) 2008, 2009, Control Yourself, Inc. * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU Affero General Public License as published by @@ -17,7 +17,9 @@ * along with this program. If not, see <http://www.gnu.org/licenses/>. */ -if (!defined('LACONICA')) { exit(1); } +if (!defined('LACONICA')) { + exit(1); +} require_once(INSTALLDIR.'/lib/twitterapi.php'); @@ -41,10 +43,10 @@ class TwitapiusersAction extends TwitterapiAction if ($email) { $user = User::staticGet('email', $email); } else { - $user = $this->get_user($apidata['api_arg']); + $user = $this->get_user($apidata['api_arg'], $apidata); } - if (!$user) { + if (empty($user)) { $this->clientError(_('Not found.'), 404, $apidata['content-type']); return; } @@ -56,7 +58,7 @@ class TwitapiusersAction extends TwitterapiAction return; } - $twitter_user = $this->twitter_user_array($profile, true); + $twitter_user = $this->twitter_user_array($user->getProfile(), true); if ($apidata['content-type'] == 'xml') { $this->init_document('xml'); |