add logs to debug
This commit is contained in:
parent
a56e888ef5
commit
00828ea222
|
@ -143,20 +143,20 @@ module Mobile
|
|||
end
|
||||
|
||||
# add by qiubing
|
||||
# commit_diff = g.commit_diff(project.gpid, sha)
|
||||
# (0...commit_diff.length).each do |i|
|
||||
# tempDiff = commit_diff[i]
|
||||
# tempDiffArry = tempDiff.diff.split("\n")
|
||||
# (2...tempDiffArry.length).each do |j|
|
||||
# if tempDiffArry[j][0] == "+" or tempDiffArry[j][0] == "-"
|
||||
# modificationLines += 1
|
||||
# end
|
||||
# end
|
||||
# end
|
||||
commit_diff = g.commit_diff(project.gpid, sha)
|
||||
(0...commit_diff.length).each do |i|
|
||||
tempDiff = commit_diff[i]
|
||||
tempDiffArry = tempDiff.diff.split("\n")
|
||||
(2...tempDiffArry.length).each do |j|
|
||||
if tempDiffArry[j][0] == "+" or tempDiffArry[j][0] == "-"
|
||||
modificationLines += 1
|
||||
end
|
||||
end
|
||||
end
|
||||
# end by qiubing
|
||||
end
|
||||
{status:0, result:result}
|
||||
# {status:0, result:result, modificationLines:modificationLines}
|
||||
# {status:0, result:result}
|
||||
{status:0, result:result, modificationLines:modificationLines}
|
||||
else
|
||||
{status:1, message: '该项目不存在或已被删除' }
|
||||
end
|
||||
|
|
Loading…
Reference in New Issue