diff options
author | Sean McGivern <sean@mcgivern.me.uk> | 2017-06-16 16:32:53 +0000 |
---|---|---|
committer | Sean McGivern <sean@mcgivern.me.uk> | 2017-06-16 16:32:53 +0000 |
commit | 352a9ed56213b6f83a679e72f9554638a0aed1ee (patch) | |
tree | 04ac45d05a67dfd71ff325ed45c8ffacaf9ec23b /app/models | |
parent | c6701d45474acab6a2d687d2e2ffdaac5c0d5491 (diff) | |
parent | ea090291bba6bb665b3631cc5a2659e6673a6959 (diff) | |
download | gitlab-ce-352a9ed56213b6f83a679e72f9554638a0aed1ee.tar.gz |
Merge branch '27070-rename-slash-commands-to-quick-actions' into 'master'
Rename "Slash commands" to "Quick actions"
Closes #27070
See merge request !11811
Diffstat (limited to 'app/models')
-rw-r--r-- | app/models/merge_request.rb | 2 | ||||
-rw-r--r-- | app/models/note.rb | 2 | ||||
-rw-r--r-- | app/models/project_services/mattermost_slash_commands_service.rb | 2 | ||||
-rw-r--r-- | app/models/project_services/slack_slash_commands_service.rb | 2 | ||||
-rw-r--r-- | app/models/project_services/slash_commands_service.rb (renamed from app/models/project_services/chat_slash_commands_service.rb) | 6 |
5 files changed, 7 insertions, 7 deletions
diff --git a/app/models/merge_request.rb b/app/models/merge_request.rb index 8e8eaea3926..ea22ab53587 100644 --- a/app/models/merge_request.rb +++ b/app/models/merge_request.rb @@ -892,7 +892,7 @@ class MergeRequest < ActiveRecord::Base !has_commits? end - def mergeable_with_slash_command?(current_user, autocomplete_precheck: false, last_diff_sha: nil) + def mergeable_with_quick_action?(current_user, autocomplete_precheck: false, last_diff_sha: nil) return false unless can_be_merged_by?(current_user) return true if autocomplete_precheck diff --git a/app/models/note.rb b/app/models/note.rb index 244bf169c29..3221e653e30 100644 --- a/app/models/note.rb +++ b/app/models/note.rb @@ -32,7 +32,7 @@ class Note < ActiveRecord::Base # Banzai::ObjectRenderer attr_accessor :user_visible_reference_count - # Attribute used to store the attributes that have ben changed by slash commands. + # Attribute used to store the attributes that have ben changed by quick actions. attr_accessor :commands_changes default_value_for :system, false diff --git a/app/models/project_services/mattermost_slash_commands_service.rb b/app/models/project_services/mattermost_slash_commands_service.rb index 56f42d63b2d..c2f887e24a0 100644 --- a/app/models/project_services/mattermost_slash_commands_service.rb +++ b/app/models/project_services/mattermost_slash_commands_service.rb @@ -1,4 +1,4 @@ -class MattermostSlashCommandsService < ChatSlashCommandsService +class MattermostSlashCommandsService < SlashCommandsService include TriggersHelper prop_accessor :token diff --git a/app/models/project_services/slack_slash_commands_service.rb b/app/models/project_services/slack_slash_commands_service.rb index 2182c1c7e4b..1c3892a3f75 100644 --- a/app/models/project_services/slack_slash_commands_service.rb +++ b/app/models/project_services/slack_slash_commands_service.rb @@ -1,4 +1,4 @@ -class SlackSlashCommandsService < ChatSlashCommandsService +class SlackSlashCommandsService < SlashCommandsService include TriggersHelper def title diff --git a/app/models/project_services/chat_slash_commands_service.rb b/app/models/project_services/slash_commands_service.rb index 8b5bc24fd3c..4592cb747a0 100644 --- a/app/models/project_services/chat_slash_commands_service.rb +++ b/app/models/project_services/slash_commands_service.rb @@ -1,6 +1,6 @@ # Base class for Chat services # This class is not meant to be used directly, but only to inherrit from. -class ChatSlashCommandsService < Service +class SlashCommandsService < Service default_value_for :category, 'chat' prop_accessor :token @@ -33,10 +33,10 @@ class ChatSlashCommandsService < Service user = find_chat_user(params) if user - Gitlab::ChatCommands::Command.new(project, user, params).execute + Gitlab::SlashCommands::Command.new(project, user, params).execute else url = authorize_chat_name_url(params) - Gitlab::ChatCommands::Presenters::Access.new(url).authorize + Gitlab::SlashCommands::Presenters::Access.new(url).authorize end end |