Merge branch 'dev-homepage-revision' into 'develop'
修复管理员不能删除项目的bug 修复管理员不能删除项目的bug See merge request !187
This commit is contained in:
commit
aa4706c13b
|
@ -1121,7 +1121,7 @@ class ProjectsController < ApplicationController
|
||||||
def destroy
|
def destroy
|
||||||
ActiveRecord::Base.transaction do
|
ActiveRecord::Base.transaction do
|
||||||
g = Gitlab.client
|
g = Gitlab.client
|
||||||
g.delete_project(@project.gpid)
|
g.delete_project(@project.gpid) unless @project.gpid.blank?
|
||||||
# 删除Trustie版本库记录
|
# 删除Trustie版本库记录
|
||||||
repoisitory = Repository.where(:project_id => @project.id, :type => GITLABTYPE).first
|
repoisitory = Repository.where(:project_id => @project.id, :type => GITLABTYPE).first
|
||||||
repoisitory.delete unless repository.blank?
|
repoisitory.delete unless repository.blank?
|
||||||
|
|
Loading…
Reference in New Issue