Skip to content

Commit

Permalink
Merge 8800a06 into efb2d97
Browse files Browse the repository at this point in the history
  • Loading branch information
rodfersou committed Aug 2, 2017
2 parents efb2d97 + 8800a06 commit 1365241
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/collective/liveblog/browser/recent_updates.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,9 @@
from collective.liveblog.browser.base import BaseView
from collective.liveblog.logger import logger
from datetime import datetime
from plone.protect.interfaces import IDisableCSRFProtection
from time import time
from zope.interface import alsoProvides
from zope.publisher.browser import BrowserView


Expand Down Expand Up @@ -79,6 +81,7 @@ def __call__(self):
# clients will wait that time before requesting the page again
expires = rfc1123_date(time() + 59) # page expires in 59 seconds
last_modified = rfc1123_date(self.context.modified())
alsoProvides(self.request, IDisableCSRFProtection)
self.request.RESPONSE.setHeader('Cache-Control', 'public')
self.request.RESPONSE.setHeader('Expires', expires)
self.request.RESPONSE.setHeader('Last-Modified', last_modified)
Expand Down

0 comments on commit 1365241

Please sign in to comment.