From 8e972b5d8b406714e7d07005076d7818b7179415 Mon Sep 17 00:00:00 2001 From: Tim Felgentreff Date: Wed, 16 Mar 2011 17:24:06 +0100 Subject: [PATCH] fix previous commit. the session might not contain a query --- lib/report/controller.rb | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/report/controller.rb b/lib/report/controller.rb index d514db6b72..910e4fab63 100644 --- a/lib/report/controller.rb +++ b/lib/report/controller.rb @@ -218,7 +218,8 @@ module Report::Controller filters = filter_params groups = group_params end - session[report_engine.name.underscore.to_sym].merge({:filters => filters, :groups => groups}) + cookie = session[report_engine.name.underscore.to_sym] || {} + session[report_engine.name.underscore.to_sym] = cookie.merge({:filters => filters, :groups => groups}) end ##