diff options
author | Toshi MARUYAMA <marutosijp2@yahoo.co.jp> | 2020-10-24 14:39:32 +0000 |
---|---|---|
committer | Toshi MARUYAMA <marutosijp2@yahoo.co.jp> | 2020-10-24 14:39:32 +0000 |
commit | 8a7bfc57a4ba1b91e185126ebf2655b7cbb16960 (patch) | |
tree | c80c0ee9dc9d6d1e6c11247521262adc6a365d23 /app/controllers/versions_controller.rb | |
parent | e665b1e8b0b2623ac6295e0970bb1846b6c5dfd2 (diff) | |
download | redmine-8a7bfc57a4ba1b91e185126ebf2655b7cbb16960.tar.gz redmine-8a7bfc57a4ba1b91e185126ebf2655b7cbb16960.zip |
shorten long line of VersionsController
git-svn-id: http://svn.redmine.org/redmine/trunk@20179 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'app/controllers/versions_controller.rb')
-rw-r--r-- | app/controllers/versions_controller.rb | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/app/controllers/versions_controller.rb b/app/controllers/versions_controller.rb index 16dd35c99..abf7c1f2a 100644 --- a/app/controllers/versions_controller.rb +++ b/app/controllers/versions_controller.rb @@ -177,9 +177,15 @@ class VersionsController < ApplicationController def retrieve_selected_tracker_ids(selectable_trackers, default_trackers=nil) if ids = params[:tracker_ids] - @selected_tracker_ids = (ids.is_a? Array) ? ids.collect { |id| id.to_i.to_s } : ids.split('/').collect { |id| id.to_i.to_s } + @selected_tracker_ids = + if ids.is_a? Array + ids.collect {|id| id.to_i.to_s} + else + ids.split('/').collect {|id| id.to_i.to_s} + end else - @selected_tracker_ids = (default_trackers || selectable_trackers).collect {|t| t.id.to_s } + @selected_tracker_ids = + (default_trackers || selectable_trackers).collect {|t| t.id.to_s} end end end |