Module: Qeweney::StaticFileCaching
- Defined in:
- lib/qeweney/response.rb
Class Method Summary collapse
Class Method Details
.file_stat_to_etag(stat) ⇒ Object
14 15 16 |
# File 'lib/qeweney/response.rb', line 14 def file_stat_to_etag(stat) "#{stat.mtime.to_i.to_s(36)}#{stat.size.to_s(36)}" end |
.file_stat_to_last_modified(stat) ⇒ Object
18 19 20 |
# File 'lib/qeweney/response.rb', line 18 def file_stat_to_last_modified(stat) stat.mtime.httpdate end |