From db4754e98cf0f87193176640853066b8c79f6e3f Mon Sep 17 00:00:00 2001 From: Andrew Nicols Date: Thu, 10 May 2018 07:43:13 +0800 Subject: [PATCH] MDL-61309 mod_forum: Remove unnecessary deletion check --- mod/forum/lib.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/mod/forum/lib.php b/mod/forum/lib.php index 8b90059139c..5a4744a6506 100644 --- a/mod/forum/lib.php +++ b/mod/forum/lib.php @@ -3545,7 +3545,7 @@ function forum_print_post($post, $discussion, $forum, &$cm, $course, $ownpost=fa } // Output ratings - if (!empty($post->deleted) && !empty($post->rating)) { + if (!empty($post->rating)) { $output .= html_writer::tag('div', $OUTPUT->render($post->rating), array('class'=>'forum-post-rating')); } @@ -3638,6 +3638,7 @@ function forum_rating_permissions($contextid, $component, $ratingarea) { * context => object the context in which the rated items exists [required] * component => The component for this module - should always be mod_forum [required] * ratingarea => object the context in which the rated items exists [required] + * * itemid => int the ID of the object being rated [required] * scaleid => int the scale from which the user can select a rating. Used for bounds checking. [required] * rating => int the submitted rating [required]