Use reference prefix for issues and merge requests in the event feed title

This commit is contained in:
George Tsiolis 2018-11-06 13:36:21 +02:00
parent 222b0f08e3
commit 780f51eaf8

View file

@ -91,11 +91,11 @@ module EventsHelper
words << "##{event.target_iid}" if event.target_iid
words << "in"
elsif event.merge_request?
words << "!#{event.target_iid}:" if event.target_iid
words << "#{Issue.reference_prefix}#{event.target_iid}:" if event.target_iid
words << event.target.title if event.target.respond_to?(:title)
words << "at"
elsif event.target
words << "##{event.target_iid}:"
words << "#{MergeRequest.reference_prefix}#{event.target_iid}:"
words << event.target.title if event.target.respond_to?(:title)
words << "at"
end