mod_log_json: Use filename from logging config
authorKim Alvefur <zash@zash.se>
Sun, 03 Nov 2019 14:33:01 +0100
changeset 3737 9a3d25311fd9
parent 3736 21cfbdaac767
child 3738 b8bd79c57040
mod_log_json: Use filename from logging config
mod_log_json/mod_log_json.lua
--- a/mod_log_json/mod_log_json.lua	Thu Oct 18 15:41:52 2018 +0200
+++ b/mod_log_json/mod_log_json.lua	Sun Nov 03 14:33:01 2019 +0100
@@ -6,7 +6,7 @@
 module:set_global();
 
 local function sink_maker(config)
-	local logfile = io.open("blah.json", "a");
+	local logfile = io.open(config.filename, "a");
 	logfile:setvbuf("no");
 	return function (source, level, message, ...)
 		local args = pack(...);