Merge branch 'develop' of http://repository.trustie.net/xianbo/trustie2 into develop
This commit is contained in:
commit
7cf837d0bf
|
@ -484,7 +484,18 @@ update
|
|||
if params[:repository_id].present?
|
||||
@repository = @project.repositories.find_by_identifier_param(params[:repository_id])
|
||||
else
|
||||
@repository = @project.repository
|
||||
# 多版本库,如果一个版本库为空则去下一个
|
||||
rep_count = @project.repositories.count
|
||||
if @project.repository.nil?
|
||||
for i in 0..rep_count
|
||||
unless @project.repositories[i].nil?
|
||||
@repository = @project.repositories[i]
|
||||
break
|
||||
end
|
||||
end
|
||||
else
|
||||
@repository = @project.repository
|
||||
end
|
||||
end
|
||||
(render_404; return false) unless @repository
|
||||
@path = params[:path].is_a?(Array) ? params[:path].join('/') : params[:path].to_s
|
||||
|
|
Loading…
Reference in New Issue