From 5b3b3684c9db4da3c5d7eac1fc3e5045de321d85 Mon Sep 17 00:00:00 2001 From: Yuki Date: Thu, 30 Apr 2015 05:21:01 +0530 Subject: [PATCH] Update justask:fix_reports --- Rakefile | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/Rakefile b/Rakefile index a58611e2..dbc8e076 100644 --- a/Rakefile +++ b/Rakefile @@ -249,6 +249,9 @@ namespace :justask do r.deleted = true r.save destroyed += 1 + elsif r.user.nil? + r.destroy + destroyed += 1 end progress.increment end @@ -328,6 +331,9 @@ namespace :justask do r.deleted = true r.save destroyed_count[:report] += 1 + elsif r.user.nil? + r.destroy + destroyed_count[:report] += 1 end progress.increment end