diff options
Diffstat (limited to 'lib/Model/Email.php')
-rw-r--r-- | lib/Model/Email.php | 19 |
1 files changed, 16 insertions, 3 deletions
diff --git a/lib/Model/Email.php b/lib/Model/Email.php index f05a82f5..08184d0c 100644 --- a/lib/Model/Email.php +++ b/lib/Model/Email.php @@ -34,12 +34,25 @@ class Email extends UserGroupClass { * @param $displayName */ public function __construct( - $id, - $displayName = '' + $id ) { - parent::__construct($id, self::TYPE, $displayName); + parent::__construct($id, self::TYPE); $this->description = \OC::$server->getL10N('polls')->t('External Email'); $this->icon = self::ICON; $this->emailAddress = $id; } + + /** + * getDisplayName + * @NoAdminRequired + * @return String + */ + public function getDisplayName() { + if (!$this->displayName) { + return $this->id; + } + return $this->displayName; + } + + } |