修复: 贡献者大小写无法正常匹配
This commit is contained in:
parent
7e0158345c
commit
6a6a257d2a
|
@ -2,17 +2,17 @@ user = $redis_cache.hgetall("v2-owner-common:#{contributor["name"]}-#{contributo
|
|||
if user.blank?
|
||||
json.contributions contributor["contributions"]
|
||||
# json.gid contributor["id"]
|
||||
json.login contributor["name"]
|
||||
json.login contributor["name"].downcase
|
||||
json.type nil
|
||||
json.name contributor["name"]
|
||||
json.name contributor["name"].downcase
|
||||
json.image_url User::Avatar.get_letter_avatar_url(contributor["name"])
|
||||
json.contribution_perc User.new(login: contributor["name"], mail: contributor["email"]).simple_contribution_perc(project, contributor["contribution_perc"])
|
||||
else
|
||||
json.contributions contributor["contributions"]
|
||||
# json.gid contributor["id"]
|
||||
json.login user["login"]
|
||||
json.login user["login"].downcase
|
||||
json.type user["type"]
|
||||
json.name user["name"]
|
||||
json.name user["name"].downcase
|
||||
json.image_url user["avatar_url"]
|
||||
db_user = User.find_by_id(user["id"])
|
||||
json.contribution_perc db_user.simple_contribution_perc(project, contributor["contribution_perc"]) if db_user.present?
|
||||
|
|
Loading…
Reference in New Issue