fixed fork列表中存在组织时显示错误

This commit is contained in:
xiaoxiaoqiong 2022-03-03 14:16:57 +08:00
parent b97c42d0ae
commit 1dd3fbc69a
1 changed files with 1 additions and 1 deletions

View File

@ -1,7 +1,7 @@
json.count @forks_count
json.users do
json.array! @fork_users.each do |f|
user = f.user
user = f.user.present? ? f.user : Organization.find_by(id: f.user_id)
json.id f.fork_project.id
json.identifier f.fork_project.identifier
json.name "#{user.try(:show_real_name)}/#{f.fork_project.try(:name)}"