* @link http://status.net/
*/
-if (!defined('STATUSNET')) {
- exit(1);
-}
-
-require_once INSTALLDIR . '/lib/apibareauth.php';
+if (!defined('GNUSOCIAL')) { exit(1); }
/**
* Ouputs the authenticating user's followers (subscribers), each with
* @license http://www.fsf.org/licensing/licenses/agpl-3.0.html GNU Affero General Public License version 3.0
* @link http://status.net/
*/
-
class ApiUserFollowersAction extends ApiSubscriptionsAction
{
/**
*
* @return array Profiles
*/
-
- function getProfiles()
+ protected function getProfiles()
{
$offset = ($this->page - 1) * $this->count;
$limit = $this->count + 1;
$subs = null;
if (isset($this->tag)) {
- $subs = $this->user->getTaggedSubscribers(
+ $subs = $this->target->getTaggedSubscribers(
$this->tag, $offset, $limit
);
} else {
- $subs = $this->user->getSubscribers(
+ $subs = $this->target->getSubscribers(
$offset,
$limit
);
$profiles = array();
- if (!empty($subs)) {
- while ($subs->fetch()) {
- $profiles[] = clone($subs);
- }
+ while ($subs->fetch()) {
+ $profiles[] = clone($subs);
}
return $profiles;
}
-
}