diff --git a/app.rb b/app.rb index 5711ce1a..cfaa0190 100644 --- a/app.rb +++ b/app.rb @@ -14,6 +14,8 @@ get %r{.+} do base_path = site_base_path subname path = File.join(base_path, (request.path =~ /\/$/ ? (request.path + 'index.html') : request.path)) + cache_control :public, max_age: 10 + if File.exist?(path) send_file path else @@ -110,4 +112,4 @@ end def template_site_title(username) "#{username.capitalize}#{username[username.length-1] == 's' ? "'" : "'s"} Site" -end \ No newline at end of file +end