--- forum.module.dist Thu Oct 7 21:00:14 2004 +++ forum.module Sat Oct 9 17:34:59 2004 @@ -44,16 +44,24 @@ * Implementation of hook_access(). */ function forum_access($op, $node) { + global $user; + if ($op == 'create') { return user_access('create forum topics'); } + + if ($op == 'update' || $op == 'delete') { + if (user_access('edit own forum topics') && ($user->uid == $node->uid)) { + return TRUE; + } + } } /** * Implementation of hook_perm(). */ function forum_perm() { - return array('create forum topics'); + return array('create forum topics', 'edit own forum topics'); } /**