From 7638b33926caa3b4062db85de80927e20d19c1e1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bj=C3=B6rn=20Geuken?= Date: Thu, 21 May 2015 18:48:07 +0200 Subject: [PATCH] Fix registration_dates_given? When the registration period is nil registration_dates_given? should return false. --- app/models/conference.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/models/conference.rb b/app/models/conference.rb index e7a0790c..9c1cde4a 100644 --- a/app/models/conference.rb +++ b/app/models/conference.rb @@ -155,7 +155,7 @@ class Conference < ActiveRecord::Base # * +false+ -> If the conference registration dates are not set # * +true+ -> If conference registration dates are set def registration_dates_given? - if registration_period && (registration_period.start_date.blank? || registration_period.end_date.blank?) + if registration_period.nil? || (registration_period.start_date.blank? || registration_period.end_date.blank?) false else true