fixed PHP notice

This commit is contained in:
Roland Gruber 2010-09-06 17:39:34 +00:00
parent d66a90bf9a
commit 27e94d9ec0
1 changed files with 9 additions and 4 deletions

View File

@ -442,11 +442,16 @@ class posixGroup extends baseModule implements passwordService {
* @return array list of possible PDF entries
*/
function get_pdfEntries() {
$members = '';
if (isset($this->attributes['memberUid'][0])) {
$members = implode(', ', $this->attributes['memberUid']);
}
return array(
get_class($this) . '_cn' => array('<block><key>' . _('Group name') . '</key><value>' . $this->attributes['cn'][0] . '</value></block>'),
get_class($this) . '_gidNumber' => array('<block><key>' . _('GID number') . '</key><value>' . $this->attributes['gidNumber'][0] . '</value></block>'),
get_class($this) . '_memberUid' => array('<block><key>' . _('Group members') . '</key><value>' . implode(', ', $this->attributes['memberUid']) . '</value></block>'),
get_class($this) . '_description' => array('<block><key>' . _('Description') . '</key><value>' . $this->attributes['description'][0] . '</value></block>'));
get_class($this) . '_cn' => array('<block><key>' . _('Group name') . '</key><value>' . $this->attributes['cn'][0] . '</value></block>'),
get_class($this) . '_gidNumber' => array('<block><key>' . _('GID number') . '</key><value>' . $this->attributes['gidNumber'][0] . '</value></block>'),
get_class($this) . '_memberUid' => array('<block><key>' . _('Group members') . '</key><value>' . $members . '</value></block>'),
get_class($this) . '_description' => array('<block><key>' . _('Description') . '</key><value>' . $this->attributes['description'][0] . '</value></block>')
);
}