From a946bdf4ae58e6aa2dea7915a5da67099a6e5c63 Mon Sep 17 00:00:00 2001 From: Matthew Wild Date: Thu, 17 Mar 2022 10:20:23 +0000 Subject: util.logger: Return sink_function from add_simple_sink() This allows a simple sink to be later removed via remove_sink() --- util/logger.lua | 1 + 1 file changed, 1 insertion(+) diff --git a/util/logger.lua b/util/logger.lua index a94a1ee1..148b98dc 100644 --- a/util/logger.lua +++ b/util/logger.lua @@ -79,6 +79,7 @@ local function add_simple_sink(simple_sink_function, levels) for _, level in ipairs(levels or {"debug", "info", "warn", "error"}) do add_level_sink(level, sink_function); end + return sink_function; end local function remove_sink(sink_function) -- cgit v1.2.3