Commit 2d4236dcf64a4b2938e9a92be56f7d167e59f2ce
1 parent
53ccf362
Exists in
master
and in
29 other branches
organizations: use display_name on short_name
Showing
1 changed file
with
6 additions
and
0 deletions
Show diff stats
app/models/organization.rb
@@ -147,6 +147,12 @@ class Organization < Profile | @@ -147,6 +147,12 @@ class Organization < Profile | ||
147 | ] | 147 | ] |
148 | end | 148 | end |
149 | 149 | ||
150 | + def short_name chars = 40 | ||
151 | + s = self.display_name | ||
152 | + s = super(chars) if s.blank? | ||
153 | + s | ||
154 | + end | ||
155 | + | ||
150 | def notification_emails | 156 | def notification_emails |
151 | emails = [contact_email].select(&:present?) + admins.map(&:email) | 157 | emails = [contact_email].select(&:present?) + admins.map(&:email) |
152 | if emails.empty? | 158 | if emails.empty? |