Skip to content

Instantly share code, notes, and snippets.

@bewitchingme
Created December 23, 2015 02:16
Show Gist options
  • Save bewitchingme/473ae113eabdabfce3d8 to your computer and use it in GitHub Desktop.
Save bewitchingme/473ae113eabdabfce3d8 to your computer and use it in GitHub Desktop.
def set_user_tz
if member_signed_in?
Time.zone = ActiveSupport::TimeZone.new(current_member.time_zone)
else
Time.zone = ActiveSupport::TimeZone.new('UTC')
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment