From 805107cd2202ddee66c4743e43804a3069508f29 Mon Sep 17 00:00:00 2001 From: Dries Buytaert Date: Mon, 2 Apr 2001 15:54:37 +0000 Subject: Commiting my work of last Sunday: - removed ban.inc and ban.module and integrated it in account.module under the name "access control" --> the ban code was not really up to standard so this has now been dealt with. This refactoring and reintegration cuts down the code size with 100 lines too. :-) (The ban.module code was really old and it showed.) - added node.module and made the other modules reuse some of this code --> cut down the code size of modules by at least 100 lines and adds stability. - added a status() function to admin.php to display a conform status message where appropriate. See admin.php for usage. - removed $theme->control() and made comments.inc handle this itself wrapped in a $theme->box(). No need to clutter the themes with such complexity --> updated all themes already. :-) - some small visual changes to some administration pages to be more consistent across different modules. --- modules/moderation.module | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'modules/moderation.module') diff --git a/modules/moderation.module b/modules/moderation.module index 5afbf009c..3b84d487c 100644 --- a/modules/moderation.module +++ b/modules/moderation.module @@ -33,15 +33,15 @@ function moderation_vote($id, $vote) { if ($node = node_get_object(nid, $id)) { if (node_post_threshold($node) <= $node->score) { - node_save(array(nid => $id, pid => $node->pid, type => $node->type, status => $status[posted])); + node_save(array(nid => $id, status => $status[posted])); watchdog("message", "node: posted '$node->title' - moderation"); } else if (node_dump_threshold($node) >= $node->score) { - node_save(array(nid => $id, pid => $node->pid, type => $node->type, status => $status[dumped])); + node_save(array(nid => $id, status => $status[dumped])); watchdog("message", "node: dumped '$node->title' - moderation"); } else if (node_timout_threshold($node) <= $node->votes) { - node_save(array(nid => $id, pid => $node->pid, type => $node->type, status => $status[expired])); + node_save(array(nid => $id, status => $status[expired])); watchdog("message", "node: expired '$node->title' - moderation"); } } -- cgit v1.2.3