From 19cae0b2f2f17a36dfdc048329bc8a4ff9e936e7 Mon Sep 17 00:00:00 2001 From: gangelo Date: Sat, 23 Dec 2023 07:31:19 -0500 Subject: [PATCH] Ensure time is in_time_zone --- lib/dsu/models/entry_group.rb | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/dsu/models/entry_group.rb b/lib/dsu/models/entry_group.rb index 01b7cf2b..d784f17f 100644 --- a/lib/dsu/models/entry_group.rb +++ b/lib/dsu/models/entry_group.rb @@ -200,7 +200,8 @@ def entry_files private def ensure_local_time(time) - time.nil? ? Time.now : time.dup.in_time_zone + time ||= Time.now + time.in_time_zone end end end