diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2020-02-17 21:09:00 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2020-02-17 21:09:00 +0300 |
commit | eb1f5a3e087b7d6a3e85f2724b5a475cc9d9d37d (patch) | |
tree | d572a6d931152ae0dd10427237f5811893438552 /app/models | |
parent | b304a72312465ed4c0a568ee6a6ea5e97f705c9b (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'app/models')
-rw-r--r-- | app/models/diff_note.rb | 2 | ||||
-rw-r--r-- | app/models/project_services/chat_message/base_message.rb | 2 | ||||
-rw-r--r-- | app/models/project_services/chat_notification_service.rb | 2 |
3 files changed, 3 insertions, 3 deletions
diff --git a/app/models/diff_note.rb b/app/models/diff_note.rb index 939d8bc4bef..e3df61dadae 100644 --- a/app/models/diff_note.rb +++ b/app/models/diff_note.rb @@ -161,7 +161,7 @@ class DiffNote < Note def positions_complete return if self.original_position.complete? && self.position.complete? - errors.add(:position, "is invalid") + errors.add(:position, "is incomplete") end def keep_around_commits diff --git a/app/models/project_services/chat_message/base_message.rb b/app/models/project_services/chat_message/base_message.rb index 529af1277b0..5c39a80b32d 100644 --- a/app/models/project_services/chat_message/base_message.rb +++ b/app/models/project_services/chat_message/base_message.rb @@ -16,7 +16,7 @@ module ChatMessage def initialize(params) @markdown = params[:markdown] || false - @project_name = params.dig(:project, :path_with_namespace) || params[:project_name] + @project_name = params[:project_name] || params.dig(:project, :path_with_namespace) @project_url = params.dig(:project, :web_url) || params[:project_url] @user_full_name = params.dig(:user, :name) || params[:user_full_name] @user_name = params.dig(:user, :username) || params[:user_name] diff --git a/app/models/project_services/chat_notification_service.rb b/app/models/project_services/chat_notification_service.rb index b84a79453c1..46c8260ab48 100644 --- a/app/models/project_services/chat_notification_service.rb +++ b/app/models/project_services/chat_notification_service.rb @@ -157,7 +157,7 @@ class ChatNotificationService < Service end def project_name - project.full_name.gsub(/\s/, '') + project.full_name end def project_url |