diff options
Diffstat (limited to 'lib/gitlab/slash_commands/presenters/access.rb')
-rw-r--r-- | lib/gitlab/slash_commands/presenters/access.rb | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/lib/gitlab/slash_commands/presenters/access.rb b/lib/gitlab/slash_commands/presenters/access.rb index e098762f290..56a960c9bbf 100644 --- a/lib/gitlab/slash_commands/presenters/access.rb +++ b/lib/gitlab/slash_commands/presenters/access.rb @@ -42,6 +42,17 @@ module Gitlab ephemeral_response(text: message) end + + def confirm(url) + text = [ + _("To ensure the highest security standards, we verify the source of all slash commands."), + Kernel.format(_("Please confirm the request by accessing %{url} through a web browser."), + url: "<#{url}|this link>"), + _("Upon successful validation, you're granted access to slash commands.") + ].join("\n\n") + + ephemeral_response(text: text) + end end end end |