Commit db5c3d60 authored by http://jneen.net/'s avatar http://jneen.net/ Committed by Felipe Artur

add Project#service_desk_address

parent 556649ef
......@@ -26,6 +26,16 @@ module EE
!public? && shared_runners_enabled? && namespace.shared_runners_minutes_limit_enabled?
end
def service_desk_address
return nil unless ::Gitlab::EE::ServiceDesk.enabled?
return nil unless self.service_desk_enabled?
refresh_service_desk_key if service_desk_mail_key.blank?
from = "service_desk+#{service_desk_mail_key}"
Gitlab::IncomingEmail.reply_address(from)
end
private
def refresh_service_desk_key
return unless ::Gitlab::EE::ServiceDesk.enabled?
......
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