diff --git a/app/models/communication/website/agenda/event.rb b/app/models/communication/website/agenda/event.rb index f23aaa1142524f814009990721a325fde30a40e8..d8066aa58f069cfd8404531bff867b3dea6ff6d1 100644 --- a/app/models/communication/website/agenda/event.rb +++ b/app/models/communication/website/agenda/event.rb @@ -156,7 +156,7 @@ class Communication::Website::Agenda::Event < ApplicationRecord title: "#{title} #{subtitle}", url: url, description: summary, - all_day: all_day? + all_day: (from_hour.nil? && to_hour.nil?) ) end @@ -187,10 +187,6 @@ class Communication::Website::Agenda::Event < ApplicationRecord end end - def all_day? - from_hour.nil? && to_hour.nil? - end - def date_and_time(date, time) Time.new(date.year, date.month, date.day, time.hour, time.min, time.sec, time.zone) end