Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-30273

Students and teachers can add additional topics to a simple forum discussion

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Blocker
    • Resolution: Fixed
    • Affects Version/s: 2.2
    • Fix Version/s: 1.9.15, 2.0.7, 2.1.4
    • Component/s: Forum
    • Labels:
    • Environment:
      qa.moodle.net
    • Database:
      Any
    • Testing Instructions:
      Hide

      1. Login as a teacher and start a discussion in a single simple discussion forum.
      2. Login as a student and enter the manual URL.
      3. Check that, as a student, it is not possible to start a discussion.

      Show
      1. Login as a teacher and start a discussion in a single simple discussion forum. 2. Login as a student and enter the manual URL. 3. Check that, as a student, it is not possible to start a discussion.
    • Affected Branches:
      MOODLE_22_STABLE
    • Fixed Branches:
      MOODLE_19_STABLE, MOODLE_20_STABLE, MOODLE_21_STABLE
    • Pull from Repository:
    • Pull Master Branch:
      wip-MDL-30273-master

      Description

      This was revealed by MDLQA-1196. It's possible for teachers and students to add new topics to a simple forum discussion by manually going to the appropriate URL (your.moodle.instance/mod/forum/post.php?forum=FORUMID). The forum page itself will still only show the first forum posting since it uses get_record() to pull the discussions, but if you have debugging turned on you'll get a db error since multiple records were found:

      Error: mdb->get_record() found more than one record!
      line 1302 of /lib/dml/moodle_database.php: call to debugging()
      line 1262 of /lib/dml/moodle_database.php: call to moodle_database->get_record_sql()
      line 1242 of /lib/dml/moodle_database.php: call to moodle_database->get_record_select()
      line 144 of /mod/forum/view.php: call to moodle_database->get_record()

      The forum shouldn't rely on the interface alone to control this behavior.

        Gliffy Diagrams

          Attachments

            Issue Links

              Activity

                People

                • Votes:
                  0 Vote for this issue
                  Watchers:
                  2 Start watching this issue

                  Dates

                  • Created:
                    Updated:
                    Resolved:
                    Fix Release Date:
                    28/Nov/11