Browse Source

oops

pull/1/head
Claudius Nicolae 12 years ago
parent
commit
f9c4804bf6
  1. 6
      app/controllers/application_controller.rb

6
app/controllers/application_controller.rb

@ -14,11 +14,7 @@ class ApplicationController < ActionController::Base
def set_timezone
old_time_zone = Time.zone
if user_signed_in? && current_user.timezone.present?
Time.zone = current_user.timezone
elsif cookies[:time_zone].present?
Time.zone = cookies[:time_zone]
end
Time.zone = cookies[:time_zone] if cookies[:time_zone].present?
yield
ensure
Time.zone = old_time_zone

Loading…
Cancel
Save