From 6bb6c0e8228ab8526a27d295c8e2b6070f7970f1 Mon Sep 17 00:00:00 2001 From: Gabriel Tofvesson Date: Mon, 14 Oct 2024 13:44:38 +0200 Subject: [PATCH] Fix global reference --- logging.lua | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/logging.lua b/logging.lua index 037adb6..d685582 100644 --- a/logging.lua +++ b/logging.lua @@ -270,10 +270,10 @@ Logging.Logger = Logger Logging.LogLevel = LogLevel function Logging.getGlobalLogger() - if _GLOBAL_LOGGER == nil then - _GLOBAL_LOGGER = Logger:new{ level = LogLevel.DEBUG, output = print } + if _G._GLOBAL_LOGGER == nil then + _G._GLOBAL_LOGGER = Logger:new{ level = LogLevel.DEBUG, output = print } end - return _GLOBAL_LOGGER + return _G._GLOBAL_LOGGER end return Logging \ No newline at end of file