use Friendica\Database\DBA;
use Friendica\DI;
use Friendica\Model\APContact;
-use Friendica\Model\Group;
+use Friendica\Model\Circle;
use Friendica\Model\Item;
use Friendica\Model\Post;
use Friendica\Model\Tag;
exit;
}
- $allowed_users = $model['allow_cid'];
- $allowed_groups = $model['allow_gid'];
- $deny_users = $model['deny_cid'];
- $deny_groups = $model['deny_gid'];
+ $allowed_users = $model['allow_cid'];
+ $allowed_circles = $model['allow_gid'];
+ $deny_users = $model['deny_cid'];
+ $deny_circles = $model['deny_gid'];
$o = DI::l10n()->t('Visible to:') . '<br />';
$l = [];
- if (count($allowed_groups)) {
- $key = array_search(Group::FOLLOWERS, $allowed_groups);
+ if (count($allowed_circles)) {
+ $key = array_search(Circle::FOLLOWERS, $allowed_circles);
if ($key !== false) {
$l[] = '<b>' . DI::l10n()->t('Followers') . '</b>';
- unset($allowed_groups[$key]);
+ unset($allowed_circles[$key]);
}
- $key = array_search(Group::MUTUALS, $allowed_groups);
+ $key = array_search(Circle::MUTUALS, $allowed_circles);
if ($key !== false) {
$l[] = '<b>' . DI::l10n()->t('Mutuals') . '</b>';
- unset($allowed_groups[$key]);
+ unset($allowed_circles[$key]);
}
- foreach (DI::dba()->selectToArray('group', ['name'], ['id' => $allowed_groups]) as $group) {
- $l[] = '<b>' . $group['name'] . '</b>';
+ foreach (DI::dba()->selectToArray('group', ['name'], ['id' => $allowed_circles]) as $circle) {
+ $l[] = '<b>' . $circle['name'] . '</b>';
}
}
$l[] = $contact['name'];
}
- if (count($deny_groups)) {
- $key = array_search(Group::FOLLOWERS, $deny_groups);
+ if (count($deny_circles)) {
+ $key = array_search(Circle::FOLLOWERS, $deny_circles);
if ($key !== false) {
$l[] = '<b><strike>' . DI::l10n()->t('Followers') . '</strike></b>';
- unset($deny_groups[$key]);
+ unset($deny_circles[$key]);
}
- $key = array_search(Group::MUTUALS, $deny_groups);
+ $key = array_search(Circle::MUTUALS, $deny_circles);
if ($key !== false) {
$l[] = '<b><strike>' . DI::l10n()->t('Mutuals') . '</strike></b>';
- unset($deny_groups[$key]);
+ unset($deny_circles[$key]);
}
- foreach (DI::dba()->selectToArray('group', ['name'], ['id' => $allowed_groups]) as $group) {
- $l[] = '<b><strike>' . $group['name'] . '</strike></b>';
+ foreach (DI::dba()->selectToArray('group', ['name'], ['id' => $allowed_circles]) as $circle) {
+ $l[] = '<b><strike>' . $circle['name'] . '</strike></b>';
}
}
case Tag::ATTRIBUTED:
$output .= DI::l10n()->t('<b>Attributed To:</b> %s<br>', implode(', ', $receiver));
break;
- }
+ }
}
return $output;