From d7cc237b82159b0ee72aa1fff71e715e9acf7bc0 Mon Sep 17 00:00:00 2001 From: Francis Irving Date: Mon, 18 Oct 2010 18:46:37 +0100 Subject: Much better way of wording this, thanks Louise --- app/models/info_request.rb | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) (limited to 'app/models/info_request.rb') diff --git a/app/models/info_request.rb b/app/models/info_request.rb index e3336a079..b485bd80e 100644 --- a/app/models/info_request.rb +++ b/app/models/info_request.rb @@ -633,12 +633,7 @@ public # History of some things that have happened def log_event(type, params) - info_request_event = InfoRequestEvent.new - info_request_event.event_type = type - info_request_event.params = params - info_request_event.info_request = self - info_request_event.save! - self.reload # so it knows about the new info_request_event + self.info_request_events.create!(:event_type => type, :params => params) end # The last response is the default one people might want to reply to -- cgit v1.2.3