]> source.dussan.org Git - sonarqube.git/commitdiff
VIEWS-43 Deleted projects are still displayed in view components
authorsimonbrandhof <simon.brandhof@gmail.com>
Mon, 18 Oct 2010 15:31:51 +0000 (15:31 +0000)
committersimonbrandhof <simon.brandhof@gmail.com>
Mon, 18 Oct 2010 15:31:51 +0000 (15:31 +0000)
sonar-server/src/main/webapp/WEB-INF/app/controllers/project_controller.rb

index d51996029b5e9cdec9809b9d79e9bdead8e6c8ec..ea8d5cfbad4f40f3bd3f0c3a92e79f90e9fd1632 100644 (file)
@@ -111,7 +111,7 @@ class ProjectController < ApplicationController
       @project = Project.by_key(params[:id])
       if @project && is_admin?(@project)
         Snapshot.update_all(['islast=?', false], ['(root_project_id=? OR project_id=?) AND islast=?', @project.id, @project.id, true])
-        Project.delete_all(['id=? OR root_id=?', @project.id, @project.id])
+        Project.delete_all(['id=? OR root_id=? or copy_resource_id=?', @project.id, @project.id, @project.id])
       end
     end
     redirect_to_default