Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 2 additions & 3 deletions lib/administrate/field/date_time.rb
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,7 @@ def date
def datetime
I18n.localize(
data.in_time_zone(timezone),
format: format,
default: data
format: format
)
end

Expand All @@ -25,7 +24,7 @@ def format
end

def timezone
options.fetch(:timezone, ::Time.zone.name || "UTC")
options.fetch(:timezone, ::Time.zone)
end
end
end
Expand Down