Module: UsersHelper
- Defined in:
- app/helpers/users_helper.rb
Overview
Copyright © 2010, Diaspora Inc. This file is
licensed under the Affero General Public License version 3 or later. See the COPYRIGHT file.
Instance Method Summary (collapse)
Instance Method Details
- (Object) first_name_or_username(user)
6 7 8 9 |
# File 'app/helpers/users_helper.rb', line 6 def first_name_or_username (user) set_name = user.person.profile.first_name (set_name.nil? || set_name.empty?) ? user.username : user.person.profile.first_name end |