summaryrefslogtreecommitdiff
path: root/app/services/notes/build_service.rb
diff options
context:
space:
mode:
Diffstat (limited to 'app/services/notes/build_service.rb')
-rw-r--r--app/services/notes/build_service.rb8
1 files changed, 8 insertions, 0 deletions
diff --git a/app/services/notes/build_service.rb b/app/services/notes/build_service.rb
index 8c250526efc..cc5c81cf280 100644
--- a/app/services/notes/build_service.rb
+++ b/app/services/notes/build_service.rb
@@ -16,6 +16,14 @@ module Notes
params.merge!(discussion.reply_attributes)
end
+ # The `confidential` param for notes is deprecated with 15.3
+ # and renamed to `internal`.
+ # We still accept `confidential` until the param gets removed from the API.
+ # Until we have not migrated the database column to `internal` we need to rename
+ # the parameter. Issue: https://gitlab.com/gitlab-org/gitlab/-/issues/367923.
+ params[:confidential] = params[:internal] || params[:confidential]
+ params.delete(:internal)
+
new_note(params, discussion)
end