diff --git a/lib/abf_worker/base_observer.rb b/lib/abf_worker/base_observer.rb index 6f2befd2d..45151da79 100644 --- a/lib/abf_worker/base_observer.rb +++ b/lib/abf_worker/base_observer.rb @@ -30,8 +30,7 @@ module AbfWorker sort_results_and_save results end - def sort_results_and_save(results, item = nil) - item ||= subject + def sort_results_and_save(results, item = subject) item.results = results.sort_by{ |r| r['file_name'] } item.save! end