diff options
author | Toshi MARUYAMA <marutosijp2@yahoo.co.jp> | 2019-10-17 16:40:43 +0000 |
---|---|---|
committer | Toshi MARUYAMA <marutosijp2@yahoo.co.jp> | 2019-10-17 16:40:43 +0000 |
commit | 9cf162108361a01bfd4fd5a59eb42260b96f7281 (patch) | |
tree | ef658697801d2c8c5d2ebbdfb8acfb976e22b2c9 /app/models/role.rb | |
parent | 57923d0450272057be793cd5a81e5fe97e4ed0c9 (diff) | |
download | redmine-9cf162108361a01bfd4fd5a59eb42260b96f7281.tar.gz redmine-9cf162108361a01bfd4fd5a59eb42260b96f7281.zip |
code cleanup: rubocop: fix Style/WhenThen in app/models/role.rb
git-svn-id: http://svn.redmine.org/redmine/trunk@18724 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'app/models/role.rb')
-rw-r--r-- | app/models/role.rb | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/app/models/role.rb b/app/models/role.rb index 7103c8f70..7fee1b50f 100644 --- a/app/models/role.rb +++ b/app/models/role.rb @@ -160,9 +160,10 @@ class Role < ActiveRecord::Base def name case builtin - when 1; l(:label_role_non_member, :default => read_attribute(:name)) - when 2; l(:label_role_anonymous, :default => read_attribute(:name)) - else; read_attribute(:name) + when 1 then l(:label_role_non_member, :default => read_attribute(:name)) + when 2 then l(:label_role_anonymous, :default => read_attribute(:name)) + else + read_attribute(:name) end end |