changeset 1406:20235e6c60c0 biblio_alt_search_auth

Correctly deleting publications.
author luisf <luis.figueira@eecs.qmul.ac.uk>
date Mon, 30 Sep 2013 18:29:35 +0100
parents 43b303a229e1
children 00a51e442fe9
files plugins/redmine_bibliography/app/controllers/publications_controller.rb
diffstat 1 files changed, 2 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/plugins/redmine_bibliography/app/controllers/publications_controller.rb	Mon Sep 30 18:27:45 2013 +0100
+++ b/plugins/redmine_bibliography/app/controllers/publications_controller.rb	Mon Sep 30 18:29:35 2013 +0100
@@ -283,8 +283,8 @@
   end
 
   def destroy
-    find_project_by_project_id
-
+    find_project_by_project_id unless params[:project_id].nil?
+    @publication = Publication.find(params[:id])
 
     @publication.destroy