comparison mod_pubsub_feeds/mod_pubsub_feeds.lua @ 3278:958f0b8b502c

mod_pubsub_feeds: Log non-HTTP errors like certificate problems etc
author Kim Alvefur <zash@zash.se>
date Sat, 25 Aug 2018 13:59:32 +0200
parents 78b11fb291a2
children e6b25054c110
comparison
equal deleted inserted replaced
3277:78b11fb291a2 3278:958f0b8b502c
158 if resp.headers then 158 if resp.headers then
159 item.etag = resp.headers.etag 159 item.etag = resp.headers.etag
160 end 160 end
161 elseif code == 304 then 161 elseif code == 304 then
162 item.last_update = time(); 162 item.last_update = time();
163 elseif code == < 100 then
164 module:log("error", "Error fetching %q: %q[%d]", item.url, data, code);
163 else 165 else
164 module:log("debug", "Unhandled status code %d when fetching %q", code, item.url); 166 module:log("debug", "Unhandled status code %d when fetching %q", code, item.url);
165 end 167 end
166 end); 168 end);
167 end 169 end