Mercurial > zeropaste
comparison app/controllers/pastes_controller.rb @ 77:2fb80ca710e0
Added cache control so it's cached by browser the first time loaded.
author | Edho Arief <edho@myconan.net> |
---|---|
date | Thu, 04 Oct 2012 10:49:23 -0700 |
parents | 8f6a0204b2a7 |
children | 0f206bd4924f |
comparison
equal
deleted
inserted
replaced
76:5635c91f4bfd | 77:2fb80ca710e0 |
---|---|
9 redirect_to paste_path(id) | 9 redirect_to paste_path(id) |
10 return | 10 return |
11 end | 11 end |
12 @paste = Paste.find(params[:id]) | 12 @paste = Paste.find(params[:id]) |
13 | 13 |
14 expires_in 1.year, :public => true | |
14 respond_to do |format| | 15 respond_to do |format| |
15 format.html # show.html.erb | 16 format.html # show.html.erb |
16 format.txt # show.txt.erb | 17 format.txt # show.txt.erb |
17 end | 18 end |
18 end | 19 end |