diff options
author | Marc Alexander <admin@m-a-styles.de> | 2016-01-10 10:06:16 +0100 |
---|---|---|
committer | Marc Alexander <admin@m-a-styles.de> | 2016-01-15 11:21:07 +0100 |
commit | 3a82ace3eb15ca1e0f4bfcfb2104cc15628ff1c3 (patch) | |
tree | dab8a92757a8333db846959c15d4a6ba8bff2e8a /phpBB/phpbb/cron/task | |
parent | 97e002cc3dc9a19b1fca10109c61b3d4e66ef201 (diff) | |
download | forums-3a82ace3eb15ca1e0f4bfcfb2104cc15628ff1c3.tar forums-3a82ace3eb15ca1e0f4bfcfb2104cc15628ff1c3.tar.gz forums-3a82ace3eb15ca1e0f4bfcfb2104cc15628ff1c3.tar.bz2 forums-3a82ace3eb15ca1e0f4bfcfb2104cc15628ff1c3.tar.xz forums-3a82ace3eb15ca1e0f4bfcfb2104cc15628ff1c3.zip |
[ticket/14402] Do not expect user id and ip to be available in cron
PHPBB3-14402
Diffstat (limited to 'phpBB/phpbb/cron/task')
-rw-r--r-- | phpBB/phpbb/cron/task/core/tidy_plupload.php | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/phpBB/phpbb/cron/task/core/tidy_plupload.php b/phpBB/phpbb/cron/task/core/tidy_plupload.php index d7364374af..027804ae68 100644 --- a/phpBB/phpbb/cron/task/core/tidy_plupload.php +++ b/phpBB/phpbb/cron/task/core/tidy_plupload.php @@ -90,7 +90,9 @@ class tidy_plupload extends \phpbb\cron\task\base } catch (\UnexpectedValueException $e) { - $phpbb_log->add('critical', $user->data['user_id'], $user->ip, 'LOG_PLUPLOAD_TIDY_FAILED', false, array( + $user_id = (empty($user->data)) ? ANONYMOUS : $user->data['user_id']; + $user_ip = (empty($user->ip)) ? '' : $user->ip; + $phpbb_log->add('critical', $user_id, $user_ip, 'LOG_PLUPLOAD_TIDY_FAILED', false, array( $this->plupload_upload_path, $e->getMessage(), $e->getTraceAsString() |