Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'lib/api/helpers/notes_helpers.rb')
-rw-r--r--lib/api/helpers/notes_helpers.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/api/helpers/notes_helpers.rb b/lib/api/helpers/notes_helpers.rb
index da499abe475..4b5335840f6 100644
--- a/lib/api/helpers/notes_helpers.rb
+++ b/lib/api/helpers/notes_helpers.rb
@@ -27,7 +27,7 @@ module API
note = ::Notes::UpdateService.new(project, current_user, opts).execute(note)
- if note.valid?
+ if note.errors.blank?
present note, with: Entities::Note
else
bad_request!("Failed to save note #{note.errors.messages}")