Subscriber lists to separate files and also Profile typing

This commit is contained in:
Mikael Nordfeldth 2016-01-06 00:57:31 +01:00
parent 59d3bbe037
commit e577e883f4
3 changed files with 26 additions and 20 deletions

View File

@ -336,23 +336,3 @@ abstract class ProfileAction extends ManagedAction
} }
} }
} }
class SubscribersMiniList extends ProfileMiniList
{
function newListItem($profile)
{
return new SubscribersMiniListItem($profile, $this->action);
}
}
class SubscribersMiniListItem extends ProfileMiniListItem
{
function linkAttributes()
{
$aAttrs = parent::linkAttributes();
if (common_config('nofollow', 'subscribers')) {
$aAttrs['rel'] .= ' nofollow';
}
return $aAttrs;
}
}

View File

@ -0,0 +1,11 @@
<?php
if (!defined('GNUSOCIAL')) { exit(1); }
class SubscribersMiniList extends ProfileMiniList
{
public function newListItem(Profile $profile)
{
return new SubscribersMiniListItem($profile, $this->action);
}
}

View File

@ -0,0 +1,15 @@
<?php
if (!defined('GNUSOCIAL')) { exit(1); }
class SubscribersMiniListItem extends ProfileMiniListItem
{
function linkAttributes()
{
$aAttrs = parent::linkAttributes();
if (common_config('nofollow', 'subscribers')) {
$aAttrs['rel'] .= ' nofollow';
}
return $aAttrs;
}
}