diff options
author | Rubén Dávila <rdavila84@gmail.com> | 2016-02-17 21:15:13 -0500 |
---|---|---|
committer | Rubén Dávila <rdavila84@gmail.com> | 2016-02-17 21:15:13 -0500 |
commit | 2770de961711076d1e8374bd943382eb14c90ad5 (patch) | |
tree | f2985fedcb69cf9fde4f9770b2d6f5ac3b4c0c68 /app/models/merge_request.rb | |
parent | ff28ac9c18231c54b9a925d26915bf3e29548ddd (diff) | |
download | gitlab-ce-2770de961711076d1e8374bd943382eb14c90ad5.tar.gz |
Reopened MRs should also be considered as open.issue_13539
Diffstat (limited to 'app/models/merge_request.rb')
-rw-r--r-- | app/models/merge_request.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/app/models/merge_request.rb b/app/models/merge_request.rb index 1be8061e53d..ea2b0e075f6 100644 --- a/app/models/merge_request.rb +++ b/app/models/merge_request.rb @@ -137,7 +137,7 @@ class MergeRequest < ActiveRecord::Base scope :by_milestone, ->(milestone) { where(milestone_id: milestone) } scope :in_projects, ->(project_ids) { where("source_project_id in (:project_ids) OR target_project_id in (:project_ids)", project_ids: project_ids) } scope :of_projects, ->(ids) { where(target_project_id: ids) } - scope :opened, -> { with_state(:opened) } + scope :opened, -> { with_states(:opened, :reopened) } scope :merged, -> { with_state(:merged) } scope :closed, -> { with_state(:closed) } scope :closed_and_merged, -> { with_states(:closed, :merged) } |