mod_swedishchef/mod_swedishchef.lua
changeset 2784 d93a73282a93
parent 2783 c53cc1ae4788
equal deleted inserted replaced
2783:c53cc1ae4788 2784:d93a73282a93
    62 
    62 
    63 	if not body then return; end
    63 	if not body then return; end
    64 	body = body:get_text();
    64 	body = body:get_text();
    65 
    65 
    66 	if body and (body:find(trigger_string, 1, true) == 1) then
    66 	if body and (body:find(trigger_string, 1, true) == 1) then
    67 		module:log("debug", body:find(trigger_string, 1, true));
    67 		module:log("debug", "Found trigger: %s", body:match(trigger_string, 1, true));
    68 		stanza[bodyindex][1] = swedish(body:gsub("^" .. trigger_string, "", 1));
    68 		stanza[bodyindex][1] = swedish(body:gsub("^" .. trigger_string, "", 1));
    69 	end
    69 	end
    70 end
    70 end
    71 
    71 
    72 if module:get_option_boolean("swedish_chef_enabled", true) then
    72 if module:get_option_boolean("swedish_chef_enabled", true) then