Minor code cleanup with group related actions (thanks brw12)

Originated from brw12 who noticed an incorrect variable name used in
an error message in actions/apigroupjoin.php:109
This commit is contained in:
Mikael Nordfeldth
2014-03-01 11:55:06 +01:00
parent 9a03ec98e7
commit fc047bd6e6
12 changed files with 30 additions and 40 deletions

View File

@@ -256,7 +256,7 @@ class Profile extends Managed_DataObject
return $stream->getNotices($offset, $limit, $since_id, $max_id);
}
function isMember($group)
function isMember(User_group $group)
{
$groups = $this->getGroups(0, null);
while ($groups instanceof User_group && $groups->fetch()) {
@@ -267,7 +267,7 @@ class Profile extends Managed_DataObject
return false;
}
function isAdmin($group)
function isAdmin(User_group $group)
{
$gm = Group_member::pkeyGet(array('profile_id' => $this->id,
'group_id' => $group->id));