Method: ActiveSupport::TimeWithZone#strftime

Defined in:
lib/active_support/time_with_zone.rb

#strftime(format) ⇒ Object

Replaces %Z directive with +zone before passing to Time#strftime, so that zone information is correct.



236
237
238
239
# File 'lib/active_support/time_with_zone.rb', line 236

def strftime(format)
  format = format.gsub(/((?:\A|[^%])(?:%%)*)%Z/, "\\1#{zone}")
  getlocal(utc_offset).strftime(format)
end