From a8059a3aca6ea77e522bef0df2499df1ee8b9cce Mon Sep 17 00:00:00 2001 From: Luke Baker Date: Tue, 14 May 2013 10:28:38 -0400 Subject: [PATCH] modify visitor find_or_create_by --- app/models/question.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/models/question.rb b/app/models/question.rb index 51edc5b..e9f8d13 100644 --- a/app/models/question.rb +++ b/app/models/question.rb @@ -183,7 +183,7 @@ class Question < ActiveRecord::Base if params[:with_prompt] if params[:with_appearance] && visitor_identifier.present? - visitor = current_user.visitors.find_or_create_by_identifier(visitor_identifier) + visitor = Visitor.find_or_create_by_identifier_and_site_id(visitor_identifier, current_user.id) last_appearance = get_first_unanswered_appearance(visitor) -- libgit2 0.21.2