diff options
author | Douwe Maan <douwe@gitlab.com> | 2016-06-22 01:18:12 +0000 |
---|---|---|
committer | Douwe Maan <douwe@gitlab.com> | 2016-06-22 01:18:12 +0000 |
commit | a3a8798a1bbc44c8055b2bf91ea94b2260480ef9 (patch) | |
tree | 403236e4af0af142ece6612d574d0e3c2c298ece | |
parent | 4dcf107b26e4e31a103b0c3097ae9cac6918c68b (diff) | |
parent | b2f60bb9a118c366ad462241bd4842c52d872d5f (diff) | |
download | gitlab-ce-a3a8798a1bbc44c8055b2bf91ea94b2260480ef9.tar.gz |
Merge branch 'fix-auto-mr-close' into 'master'
Fix auto-MR-close text from branch name
## What does this MR do?
Fix the MR-auto-close feature if a branch name begins with an issue IID.
## Are there points in the code the reviewer needs to double check?
It's one line, so check that line thoroughly :smiley:
## Why was this MR needed?
When I create a new MR from a branch starting with an issue IID, the description doesn't get suffixed with the 'Closes #blahblah' that it should do.
## What are the relevant issue numbers?
Don't think there are any.
## Screenshots (if relevant)
## Does this MR meet the acceptance criteria?
- [ ] [CHANGELOG](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/CHANGELOG) entry added
See merge request !4836
-rw-r--r-- | CHANGELOG | 1 | ||||
-rw-r--r-- | app/services/merge_requests/build_service.rb | 2 |
2 files changed, 2 insertions, 1 deletions
diff --git a/CHANGELOG b/CHANGELOG index d9abb322f30..72679b89d82 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -13,6 +13,7 @@ v 8.9.0 (unreleased) - Fix endless redirections when accessing user OAuth applications when they are disabled - Allow enabling wiki page events from Webhook management UI - Bump rouge to 1.11.0 + - Fix MR-auto-close text added to description - Fix issue with arrow keys not working in search autocomplete dropdown - Fix an issue where note polling stopped working if a window was in the background during a refresh. diff --git a/app/services/merge_requests/build_service.rb b/app/services/merge_requests/build_service.rb index 1b48899bb0a..7fe57747265 100644 --- a/app/services/merge_requests/build_service.rb +++ b/app/services/merge_requests/build_service.rb @@ -83,7 +83,7 @@ module MergeRequests closes_issue = "Closes ##{iid}" if merge_request.description.present? - merge_request.description << closes_issue.prepend("\n") + merge_request.description += closes_issue.prepend("\n") else merge_request.description = closes_issue end |