Diff

mod_pubsub_feed/mod_pubsub_feed.lua @ 400:f42fe4229f8a

mod_pubsub_feed: Fix timestamp on Windows, which has no %T
author Kim Alvefur <zash@zash.se>
date Wed, 24 Aug 2011 11:29:02 +0200
parent 325:4e50e591a7fc
child 401:c85397063eca
line wrap: on
line diff
--- a/mod_pubsub_feed/mod_pubsub_feed.lua	Wed Aug 10 05:30:08 2011 +0500
+++ b/mod_pubsub_feed/mod_pubsub_feed.lua	Wed Aug 24 11:29:02 2011 +0200
@@ -137,7 +137,8 @@
 function fetch(item, callback) -- HTTP Pull
 	local headers = { };
 	if item.data and item.last_update then
-		headers["If-Modified-Since"] = date("!%a, %d %b %Y %T %Z", item.last_update);
+		headers["If-Modified-Since"] = date("!%a, %d %b %Y %H:%M:%S %Z", item.last_update);
+		--COMPAT We could have saved 6 bytes here, but Microsoft apparently hates %T, so you got this gigantic comment instead.
 	end
 	http.request(item.url, { headers = headers }, function(data, code, req) 
 		if code == 200 then