comparison mod_muc_log_http/muc_log_http/mod_muc_log_http.lua @ 385:fec9bc52aa42

mod_muc_log_http: Generate component room list page even when there are no rooms.
author Waqas Hussain <waqas20@gmail.com>
date Mon, 25 Jul 2011 02:21:40 +0500
parents 79983e658bb5
children d54dbbfda3bb
comparison
equal deleted inserted replaced
384:79983e658bb5 385:fec9bc52aa42
114 local node = splitJid(jid); 114 local node = splitJid(jid);
115 if not room._data.hidden and node then 115 if not room._data.hidden and node then
116 rooms = rooms .. html.rooms.bit:gsub("###ROOM###", node):gsub("###COMPONENT###", component); 116 rooms = rooms .. html.rooms.bit:gsub("###ROOM###", node):gsub("###COMPONENT###", component);
117 end 117 end
118 end 118 end
119 if rooms ~= "" then 119 return html.rooms.body:gsub("###ROOMS_STUFF###", rooms):gsub("###COMPONENT###", component);
120 return html.rooms.body:gsub("###ROOMS_STUFF###", rooms):gsub("###COMPONENT###", component);
121 end
122 end 120 end
123 end 121 end
124 122
125 -- Calendar stuff 123 -- Calendar stuff
126 local function getDaysForMonth(month, year) 124 local function getDaysForMonth(month, year)