X-Git-Url: http://dolda2000.com/gitweb/?p=wrw.git;a=blobdiff_plain;f=wrw%2Fresp.py;h=69635f8589ebb133ed4dfae0707e1d57a2fbaef1;hp=b62ce0e4bdefe58d6473977f77c78eaadea9e223;hb=2a5a8ce70a0107b7bfd5bd3459ae4aae3a7558e2;hpb=8fec8547c47c0452333972f554f328d0c8e61be2 diff --git a/wrw/resp.py b/wrw/resp.py index b62ce0e..69635f8 100644 --- a/wrw/resp.py +++ b/wrw/resp.py @@ -71,3 +71,9 @@ class redirect(dispatch.restart): req.status(self.status, "Redirect") req.ohead["Location"] = proto.appendurl(proto.requrl(req), self.url) return [] + +class unmodified(dispatch.restart): + def handle(self, req): + req.status(304, "Not Modified") + req.ohead["Content-Length"] = "0" + return []