No pagination when no groups shown... :)

This commit is contained in:
Mikael Nordfeldth 2013-11-04 16:57:30 +01:00
parent 413f040673
commit 3552bf4d94

View File

@ -140,14 +140,13 @@ class UsergroupsAction extends ProfileAction
if ($groups instanceof User_group) { if ($groups instanceof User_group) {
$gl = new GroupList($groups, $this->user, $this); $gl = new GroupList($groups, $this->user, $this);
$cnt = $gl->show(); $cnt = $gl->show();
$this->pagination($this->page > 1, $cnt > GROUPS_PER_PAGE,
$this->page, 'usergroups',
array('nickname' => $this->user->nickname));
} else { } else {
$this->showEmptyListMessage(); $this->showEmptyListMessage();
} }
$this->pagination($this->page > 1, $cnt > GROUPS_PER_PAGE,
$this->page, 'usergroups',
array('nickname' => $this->user->nickname));
Event::handle('EndShowUserGroupsContent', array($this)); Event::handle('EndShowUserGroupsContent', array($this));
} }
} }