summaryrefslogtreecommitdiff
path: root/app/controllers/concerns
diff options
context:
space:
mode:
authorRémy Coutable <remy@rymai.me>2016-03-22 19:19:53 +0100
committerRémy Coutable <remy@rymai.me>2016-03-23 12:02:15 +0100
commit7dc16346bba174d6075cf438adcd70a5596ba935 (patch)
treebdb093b32967dae0946476747a223124ee65f09f /app/controllers/concerns
parent703f7c5d579a6ab6d7592c24f8e3f2813d9d1703 (diff)
downloadgitlab-ce-7dc16346bba174d6075cf438adcd70a5596ba935.tar.gz
Fix an issue causing the Dashboard/Milestones page to be blank
Diffstat (limited to 'app/controllers/concerns')
-rw-r--r--app/controllers/concerns/global_milestones.rb5
1 files changed, 4 insertions, 1 deletions
diff --git a/app/controllers/concerns/global_milestones.rb b/app/controllers/concerns/global_milestones.rb
index 54ea1e454fc..f5eace47df4 100644
--- a/app/controllers/concerns/global_milestones.rb
+++ b/app/controllers/concerns/global_milestones.rb
@@ -6,7 +6,10 @@ module GlobalMilestones
@milestones = MilestonesFinder.new.execute(@projects, params)
@milestones = GlobalMilestone.build_collection(@milestones)
@milestones = @milestones.sort_by { |x| x.due_date.nil? ? epoch : x.due_date }
- @milestones = Kaminari.paginate_array(@milestones).page(params[:page])
+
+ if request.format == :html
+ @milestones = Kaminari.paginate_array(@milestones).page(params[:page])
+ end
end
def milestone