From: Marcel Werk Date: Tue, 22 Apr 2014 22:08:23 +0000 (+0200) Subject: Fixed modification log issue X-Git-Tag: 2.0.6~21 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=da83d14ce8b6d04dd68af591e24b1fb36a0889ae;p=GitHub%2FWoltLab%2FWCF.git Fixed modification log issue --- diff --git a/wcfsetup/install/files/lib/system/log/modification/ModificationLogHandler.class.php b/wcfsetup/install/files/lib/system/log/modification/ModificationLogHandler.class.php index 47a1bb08c9..5cc4b1ac09 100644 --- a/wcfsetup/install/files/lib/system/log/modification/ModificationLogHandler.class.php +++ b/wcfsetup/install/files/lib/system/log/modification/ModificationLogHandler.class.php @@ -65,7 +65,14 @@ class ModificationLogHandler extends SingletonFactory { throw new SystemException("Object type '".$objectType."' not found within definition 'com.woltlab.wcf.modifiableContent'"); } - if ($userID === null) $userID = WCF::getUser()->userID; + if ($userID === null) { + if (WCF::getUser()->userID) { + $userID = WCF::getUser()->userID; + } + else if ($username === null) { + $username = 'System'; + } + } if ($username === null) { if (WCF::getUser()->username) $username = WCF::getUser()->username; else $username = '';