Moodle
  1. Moodle
  2. MDL-27305

forum_get_view_actions() is Out of Date

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Critical Critical
    • Resolution: Fixed
    • Affects Version/s: 1.9.11
    • Fix Version/s: 2.0.4, 2.1.1
    • Component/s: Forum
    • Labels:
    • Rank:
      16996

      Description

      forum_get_view_actions() is out of date. Forum views are logged with action "view forum" but this is not included in the forum view action list. This leads to situations such as reports showing that users posted in forums without viewing them.

      I'm attaching a patch to add "view forum" to the forum_get_view_actions() function.

        Activity

        Hide
        Michael Blake added a comment -

        Can we get someone to test this patch please? An MP has reported this as an issue for their client.

        Show
        Michael Blake added a comment - Can we get someone to test this patch please? An MP has reported this as an issue for their client.
        Hide
        Helen Foster added a comment -

        Chris, thanks for your report with patch. Do you know whether the issue affects 2.0 as well as 1.9?

        Show
        Helen Foster added a comment - Chris, thanks for your report with patch. Do you know whether the issue affects 2.0 as well as 1.9?
        Hide
        Chris Follin added a comment -

        Helen, it appears that 2.0 does have the same problem. mod/forum/view.php has an add_to_log() call with an action of "view forum" but forum_get_view_actions() in mod/forum/lib.php does not have "view forum" as an action.

        Show
        Chris Follin added a comment - Helen, it appears that 2.0 does have the same problem. mod/forum/view.php has an add_to_log() call with an action of "view forum" but forum_get_view_actions() in mod/forum/lib.php does not have "view forum" as an action.
        Hide
        Sam Hemelryk added a comment -

        Hi Chris,
        Thanks for the patch - it looked spot on to me so I've turned it into git branches required for integration (I also made you the author of the changes... credit where it is deserved!) and I'm putting this up for integration now.

        Cheers
        Sam

        Show
        Sam Hemelryk added a comment - Hi Chris, Thanks for the patch - it looked spot on to me so I've turned it into git branches required for integration (I also made you the author of the changes... credit where it is deserved!) and I'm putting this up for integration now. Cheers Sam
        Hide
        Petr Škoda added a comment -

        Integrated, thanks.

        Show
        Petr Škoda added a comment - Integrated, thanks.
        Hide
        Petr Škoda added a comment -

        No testing should be necessary, thanks again.

        Show
        Petr Škoda added a comment - No testing should be necessary, thanks again.

          People

          • Votes:
            1 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: