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

Blocked user auto message marking looses message info

    XMLWordPrintable

Details

    • MOODLE_26_STABLE, MOODLE_27_STABLE
    • MOODLE_26_STABLE, MOODLE_27_STABLE
    • MDL-46620-master
    • Hide

      You will need two browsers open, and logged in as two different users, U1 and U2. You will also need a third user, U3

      1. U1: Add U2 and U3 as a messaging contacts.
      2. U2: Send a message to U1
      3. U1: Logout
      4. U1: Login
      5. U1: Verify that you get a popup notification for the message, click through and read it.
      6. U1: Click to change to the message stream for U3.
      7. U2: Send a message to U1
      8. U1: While still viewing U3's messages, click the block icon next to U2
      9. U1: Logout
      10. U1: Login
      11. U1: You should not see a popup notification.
      12. In the database, look at the last record in mdl_message_read, confirm that it is the message that you sent, and that the message has content in 'fullmessage' and that timecreated appears proper (not 0)
      Show
      You will need two browsers open, and logged in as two different users, U1 and U2. You will also need a third user, U3 U1: Add U2 and U3 as a messaging contacts. U2: Send a message to U1 U1: Logout U1: Login U1: Verify that you get a popup notification for the message, click through and read it. U1: Click to change to the message stream for U3. U2: Send a message to U1 U1: While still viewing U3's messages, click the block icon next to U2 U1: Logout U1: Login U1: You should not see a popup notification. In the database, look at the last record in mdl_message_read, confirm that it is the message that you sent, and that the message has content in 'fullmessage' and that timecreated appears proper (not 0)

    Description

      The fix in MDL-42214 made it so message that are from blocked users are automatically marked as read during login.

      The problem is that message_mark_message_read must be passed a full message, but the optimized sql passes an abbreviated message object, without the actual message body, loosing key info (the full message body, message time, etc).

      Attachments

        Issue Links

          Activity

            People

              emerrill Eric Merrill
              emerrill Eric Merrill
              Andrew Davis Andrew Davis
              Eloy Lafuente (stronk7) Eloy Lafuente (stronk7)
              Adrian Greeve Adrian Greeve
              David Woloszyn, Huong Nguyen, Jake Dallimore, Meirza, Michael Hawkins, Raquel Ortega, Safat Shahin, Stevani Andolo
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:
                8/Sep/14