Files
gitlink-forgeplus/app/views/repositories/_last_commit.json.jbuilder
Jasder 6d51657ecf FIX get latest commit bug
(cherry picked from commit b7e23a62d0)
2021-01-20 14:30:49 +08:00

10 lines
348 B
Ruby

if latest_commit.blank?
json.nil!
else
json.message latest_commit['message']
json.sha latest_commit['sha']
json.created_at render_format_time_with_unix(latest_commit['created_at'].to_i)
json.time_from_now time_from_now(render_format_time_with_unix(latest_commit['created_at'].to_i))
json.created_at_unix latest_commit['created_at']
end