Don't allow nil references to get added to results

This commit is contained in:
Robert Speicher 2015-04-23 14:01:35 -04:00
parent 2403a28b3f
commit c0a97d70ef

View file

@ -42,6 +42,8 @@ module Gitlab
# type - Singular Symbol reference type (e.g., :issue, :user, etc.)
# value - Object to add
def push_result(type, value)
return if value.nil?
result[:references][type].push(value)
end