summaryrefslogtreecommitdiff
path: root/app/helpers/issues_helper.rb
diff options
context:
space:
mode:
authorFelipe Artur <felipefac@gmail.com>2016-04-06 11:02:22 -0300
committerFelipe Artur <felipefac@gmail.com>2016-04-06 11:02:22 -0300
commit9e6c61372fe0f7f2199f4e8f72b3c4e4a4219020 (patch)
treee8549747bf296c95f94cb9aed6a9782ec431e4bd /app/helpers/issues_helper.rb
parent74313988aca5de1e65940d311f0f87e9da1b93c2 (diff)
downloadgitlab-ce-9e6c61372fe0f7f2199f4e8f72b3c4e4a4219020.tar.gz
Fix milestone removal problem when editing issues
Diffstat (limited to 'app/helpers/issues_helper.rb')
-rw-r--r--app/helpers/issues_helper.rb1
1 files changed, 1 insertions, 0 deletions
diff --git a/app/helpers/issues_helper.rb b/app/helpers/issues_helper.rb
index 24b90fef4fe..414056c809f 100644
--- a/app/helpers/issues_helper.rb
+++ b/app/helpers/issues_helper.rb
@@ -52,6 +52,7 @@ module IssuesHelper
def milestone_options(object)
milestones = object.project.milestones.active.reorder(due_date: :asc, title: :asc).to_a
+ milestones.unshift(object.milestone) if object.milestone.present? && object.milestone.closed?
milestones.unshift(Milestone::None)
options_from_collection_for_select(milestones, 'id', 'title', object.milestone_id)