Commit 56ce4667 authored by Peter Leitzen's avatar Peter Leitzen

You cannot `/award` a Commit

parent fbd0f162
...@@ -393,6 +393,7 @@ module QuickActions ...@@ -393,6 +393,7 @@ module QuickActions
end end
params ':emoji:' params ':emoji:'
condition do condition do
issuable.is_a?(Issuable) &&
issuable.persisted? issuable.persisted?
end end
parse_params do |emoji_param| parse_params do |emoji_param|
......
...@@ -980,6 +980,12 @@ describe QuickActions::InterpretService do ...@@ -980,6 +980,12 @@ describe QuickActions::InterpretService do
let(:issuable) { issue } let(:issuable) { issue }
end end
end end
context 'if issuable is a Commit' do
let(:content) { '/award :100:' }
let(:issuable) { commit }
it_behaves_like 'empty command'
end
end end
context '/shrug command' do context '/shrug command' do
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment