From 7911c374e86ef8fa69c4545867b9d9d3de12d5c6 Mon Sep 17 00:00:00 2001 From: 8chan Date: Wed, 25 Feb 2015 17:21:49 -0800 Subject: 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) --- post.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'post.php') diff --git a/post.php b/post.php index 06a9dc74..0d3292bb 100644 --- a/post.php +++ b/post.php @@ -70,9 +70,11 @@ if (isset($_POST['delete'])) { if (isset($_POST['file'])) { // Delete just the file deleteFile($id); + modLog("User deleted file from his own post #$id"); } else { // Delete entire post deletePost($id); + modLog("User deleted his own post #$id"); } _syslog(LOG_INFO, 'Deleted post: ' . @@ -233,7 +235,6 @@ if (isset($_POST['delete'])) { checkBan($board['uri']); if ($post['mod'] = isset($_POST['mod']) && $_POST['mod']) { - require 'inc/mod/auth.php'; check_login(false); if (!$mod) { // Liar. You're not a mod. @@ -945,7 +946,7 @@ if (isset($_POST['delete'])) { $build_pages = range(1, $config['max_pages']); if ($post['op']) - clean(); + clean($pid); event('post-after', $post); -- cgit v1.3