From 6cfd13726fbce725633d95140dd0e4bf1779c5db Mon Sep 17 00:00:00 2001 From: manojmj Date: Wed, 24 Jul 2019 19:45:50 +0530 Subject: CE: Add project download & project export audit event This change adds audit events for download of repository and export of project. --- lib/api/helpers.rb | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'lib/api/helpers.rb') diff --git a/lib/api/helpers.rb b/lib/api/helpers.rb index 8ae42c6dadd..1aa6dc44bf7 100644 --- a/lib/api/helpers.rb +++ b/lib/api/helpers.rb @@ -544,5 +544,9 @@ module API params[:archived] end + + def ip_address + env["action_dispatch.remote_ip"].to_s || request.ip + end end end -- cgit v1.2.1