diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2020-07-30 21:09:39 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2020-07-30 21:09:39 +0300 |
commit | 1b26aaa633642ea33f1fb9d7e8680892c8ca795d (patch) | |
tree | 2f472efc1b86f43857082132ed58e2b24e46ab39 /app/models/audit_event.rb | |
parent | e65a1b9830b8746fefd18744a39d559cbf58c99e (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'app/models/audit_event.rb')
-rw-r--r-- | app/models/audit_event.rb | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/app/models/audit_event.rb b/app/models/audit_event.rb index 6d46009fa4d..e7cfa30a892 100644 --- a/app/models/audit_event.rb +++ b/app/models/audit_event.rb @@ -58,6 +58,12 @@ class AuditEvent < ApplicationRecord end end + def as_json(options = {}) + super(options).tap do |json| + json['ip_address'] = self.ip_address.to_s + end + end + private def default_author_value |