summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBob Van Landuyt <bob@gitlab.com>2017-03-08 01:20:05 +0100
committerBob Van Landuyt <bob@gitlab.com>2017-03-13 08:27:51 +0100
commit843092b631ec667aff3cb3617c40a6eef811c097 (patch)
treed48609a74c546eb0cfb414b60dab5c908399b239
parent5eee47758ccba75e2d1d7fa1c30b98a4c2820108 (diff)
downloadgitlab-ce-843092b631ec667aff3cb3617c40a6eef811c097.tar.gz
Don't filter params and merge them back in later
By building the issue before filtering
-rw-r--r--app/services/issues/create_service.rb9
1 files changed, 2 insertions, 7 deletions
diff --git a/app/services/issues/create_service.rb b/app/services/issues/create_service.rb
index f40cb4a8fa0..aba590494d6 100644
--- a/app/services/issues/create_service.rb
+++ b/app/services/issues/create_service.rb
@@ -4,16 +4,11 @@ module Issues
include ResolveDiscussions
def execute
+ @issue = BuildService.new(project, current_user, params).execute
+
filter_spam_check_params
filter_resolve_discussion_params
- issue_attributes = params.merge(
- merge_request_for_resolving_discussions: merge_request_for_resolving_discussions_iid,
- discussion_to_resolve: discussion_to_resolve_id
- )
-
- @issue = BuildService.new(project, current_user, issue_attributes).execute
-
create(@issue)
end