]> git.mjollnir.org Git - moodle.git/commitdiff
Discussions from a forum of type 'single' should not be splittable. Merge from 1...
authorvyshane <vyshane>
Mon, 25 Sep 2006 05:12:01 +0000 (05:12 +0000)
committervyshane <vyshane>
Mon, 25 Sep 2006 05:12:01 +0000 (05:12 +0000)
mod/forum/post.php

index 812457a1e4cf63efbf03fc3ceb33aed4e04ec7b9..af28b03f0b5cec3b670c44596286ceddfe8f0195 100644 (file)
         if (!$forum = get_record("forum", "id", $discussion->forum)) {
             error("The forum number was incorrect ($discussion->forum)");
         }
+        if ($forum->type == 'single') {
+            error('Discussions from this forum cannot be split');
+        }
         if (!$post->parent) {
             error('This is already the first post in the discussion');
         }