gitlab-org--gitlab-foss/app/serializers/analytics_commit_entity.rb

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

16 lines
305 B
Ruby
Raw Normal View History

# frozen_string_literal: true
2016-11-15 12:23:17 +00:00
class AnalyticsCommitEntity < CommitEntity
include EntityDateHelper
expose :short_id, as: :short_sha
expose :total_time do |commit|
distance_of_time_as_hash(request.total_time.to_f)
2016-11-15 12:23:17 +00:00
end
unexpose :author_name
unexpose :author_email
unexpose :message
end