diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2022-08-03 12:11:38 +0000 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2022-08-03 12:11:38 +0000 |
commit | 91035102b4e313787a45217ff12bb88f7f48bf20 (patch) | |
tree | 0b4c1147165bee39e199acae3d606683de97e087 /lib/gitlab/quick_actions | |
parent | dda49284fcd29d631c2b7642a6430fdfa5793f48 (diff) | |
download | gitlab-ce-91035102b4e313787a45217ff12bb88f7f48bf20.tar.gz |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'lib/gitlab/quick_actions')
-rw-r--r-- | lib/gitlab/quick_actions/dsl.rb | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/lib/gitlab/quick_actions/dsl.rb b/lib/gitlab/quick_actions/dsl.rb index a2dfcc6de9a..dfbc00ef847 100644 --- a/lib/gitlab/quick_actions/dsl.rb +++ b/lib/gitlab/quick_actions/dsl.rb @@ -30,11 +30,11 @@ module Gitlab # # Awesome code block # end def desc(text = '', &block) - @description = block_given? ? block : text + @description = block || text end def warning(text = '', &block) - @warning = block_given? ? block : text + @warning = block || text end def icon(string = '') @@ -51,7 +51,7 @@ module Gitlab # # Awesome code block # end def params(*params, &block) - @params = block_given? ? block : params + @params = block || params end # Allows to give an explanation of what the command will do when @@ -67,7 +67,7 @@ module Gitlab # # Awesome code block # end def explanation(text = '', &block) - @explanation = block_given? ? block : text + @explanation = block || text end # Allows to provide a message about quick action execution result, success or failure. @@ -96,7 +96,7 @@ module Gitlab # end # def execution_message(text = '', &block) - @execution_message = block_given? ? block : text + @execution_message = block || text end # Allows to define type(s) that must be met in order for the command |