Unverified Commit cf38e59c by Scott Committed by GitHub

Merge pull request #670 from pupi1985/patch-116

Allow closed and hidden questions to be deleted with one click
parents 5a8ec779 a3e6602d
......@@ -220,6 +220,11 @@ function qa_page_q_post_rules($post, $parentpost = null, $siblingposts = null, $
if (isset($childposts)) {
foreach ($childposts as $childpost) {
// Skip the child post if it is a note
if ($childpost['basetype'] === 'N') {
continue;
}
if ($childpost['parentid'] == $post['postid']) {
// this post has comments
$rules['deleteable'] = false;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment