return false;
}
$user = common_current_user();
- if (!$user->isAdmin($this->group)) {
+ if (!$user->isAdmin($this->group) &&
+ !$user->hasRight(Right::MAKEGROUPADMIN)) {
$this->clientError(_('Only an admin can make another user an admin.'), 401);
return false;
}
'profile_id' => $this->profile->id));
if (empty($member)) {
- $this->serverError(_('Can\'t get membership record for %1$s in group %2$s'),
+ $this->serverError(_('Can\'t get membership record for %1$s in group %2$s.'),
$this->profile->getBestName(),
$this->group->getBestName());
}
if (!$result) {
common_log_db_error($member, 'UPDATE', __FILE__);
- $this->serverError(_('Can\'t make %1$s an admin for group %2$s'),
+ $this->serverError(_('Can\'t make %1$s an admin for group %2$s.'),
$this->profile->getBestName(),
$this->group->getBestName());
}