A free, self-hostable news aggregator…
Minz::Log bug when currentUser is empty string
Alexandre Alapetite576f9737a8aa
diff --git a/lib/Minz/Log.php b/lib/Minz/Log.phpindex 2a9e10993..9559a0bd4 100644--- a/lib/Minz/Log.php+++ b/lib/Minz/Log.php@@ -42,7 +42,11 @@ class Minz_Log {|| ($env === 'production'&& ($level >= Minz_Log::NOTICE)))) {if ($file_name === null) {- $file_name = join_path(USERS_PATH, Minz_Session::param('currentUser', '_'), 'log.txt');+ $username = Minz_Session::param('currentUser', '');+ if ($username == '') {+ $username = '_';+ }+ $file_name = join_path(USERS_PATH, $username, 'log.txt');}switch ($level) {