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

Incorrect URL in mod/forum get_unsubscribediscussionlink

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 3.0.1, 3.1
    • Fix Version/s: 3.0.3
    • Component/s: Forum
    • Labels:
    • Testing Instructions:
      Hide
      1. Login as an admin.
      2. Set up SMTP settings so that the site can send forum posts through email.
      3. Create a course with a forum.
      4. Login as a student with a valid email address.
      5. Create a discussion and make a post.
        • Confirm that the Subscribe to/Unsubscribe from this discussion links work as expected in the discussion page.
      6. Subscribe to the discussion.
      7. Login as another user and post a reply to the discussion.
      8. Check the email for the posted reply to the discussion and check the Unsubscribe from this discussion link.
        • Confirm in the email that the Unsubscribe from this discussion link has the URL

          https://[YOUR_MOODLE_ADDRESS]/mod/forum/subscribe.php?id=[FORUM_ID]&d=[DISCUSSION_ID]

      9. Click on the Unsubscribe from this discussion link.
        • Confirm that you don't get a 404 error and that you get unsubscribed from the discussion.
      Show
      Login as an admin. Set up SMTP settings so that the site can send forum posts through email. Create a course with a forum. Login as a student with a valid email address. Create a discussion and make a post. Confirm that the Subscribe to/Unsubscribe from this discussion links work as expected in the discussion page. Subscribe to the discussion. Login as another user and post a reply to the discussion. Check the email for the posted reply to the discussion and check the Unsubscribe from this discussion link. Confirm in the email that the Unsubscribe from this discussion link has the URL https://[YOUR_MOODLE_ADDRESS]/mod/forum/subscribe.php?id=[FORUM_ID]&d=[DISCUSSION_ID] Click on the Unsubscribe from this discussion link. Confirm that you don't get a 404 error and that you get unsubscribed from the discussion.
    • Affected Branches:
      MOODLE_30_STABLE, MOODLE_31_STABLE
    • Fixed Branches:
      MOODLE_30_STABLE
    • Pull from Repository:
    • Pull Master Branch:
      patch-11

      Description

      The function 'get_unsubscribediscussionlink' returns a URL like this:
      '/mod/discussion/subscribe.php'

      https://github.com/moodle/moodle/blob/master/mod/forum/classes/output/forum_post.php#L341

      That doesn't exist!
      Looks like it should be going to '/mod/forum/subscribe.php'?

        Attachments

          Issue Links

            Activity

              People

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

                Dates

                • Created:
                  Updated:
                  Resolved:
                  Fix Release Date:
                  14/Mar/16