diff options
| author | 8chan <admin@8chan.co> | 2015-02-25 17:21:49 -0800 |
|---|---|---|
| committer | czaks <marcin@6irc.net> | 2016-05-06 15:44:26 +0200 |
| commit | 7911c374e86ef8fa69c4545867b9d9d3de12d5c6 (patch) | |
| tree | 217ac7d32eff8acfaa6b08991dc792750edcedc3 /inc/mod/auth.php | |
| parent | 6dd1420f91410531bb2dac506f821d959bf74d0a (diff) | |
Public action logs commit (log.php)
Note: In a previous commit, I began making inc/mod/auth.php more modular with the check_login() function. Including it does NOT check mod login by default anymore like it does on vichan. You have to call check_login(). I've finally included it in inc/functions.php. If you have any custom pages that use inc/mod/auth.php, just including functions.php is enough now.
===================================
Also: backports 351375185e5 (early 404)
Diffstat (limited to 'inc/mod/auth.php')
| -rw-r--r-- | inc/mod/auth.php | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/inc/mod/auth.php b/inc/mod/auth.php index 009e93ad..42f34196 100644 --- a/inc/mod/auth.php +++ b/inc/mod/auth.php @@ -130,7 +130,7 @@ function destroyCookies() { function modLog($action, $_board=null) { global $mod, $board, $config; $query = prepare("INSERT INTO ``modlogs`` VALUES (:id, :ip, :board, :time, :text)"); - $query->bindValue(':id', $mod['id'], PDO::PARAM_INT); + $query->bindValue(':id', (isset($mod['id']) ? $mod['id'] : -1), PDO::PARAM_INT); $query->bindValue(':ip', $_SERVER['REMOTE_ADDR']); $query->bindValue(':time', time(), PDO::PARAM_INT); $query->bindValue(':text', $action); |
