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

Chat uses require instead of require_once

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 3.9.3, 3.10
    • Fix Version/s: 3.9.4, 3.10.1
    • Component/s: Chat
    • Labels:

      Description

      A few pages in chat use require() instead of require_once() to import their lib.php. 

      This will cause the chat to break if mod/chat/lib.php is imported earlier in the page load - as can happen with certain filters (like Ally).

      I did a quick grep, and this is the only place in core where a mod imports its lib.php using require().

        Attachments

          Activity

            People

            Assignee:
            emerrill Eric Merrill
            Reporter:
            emerrill Eric Merrill
            Peer reviewer:
            Tim Hunt Tim Hunt
            Integrator:
            Sara Arjona (@sarjona) Sara Arjona (@sarjona)
            Tester:
            Janelle Barcega Janelle Barcega
            Participants:
            Component watchers:
            Amaia Anabitarte, Carlos Escobedo, Ferran Recio, Ilya Tregubov, Sara Arjona (@sarjona)
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:
              Fix Release Date:
              18/Jan/21

                Time Tracking

                Estimated:
                Original Estimate - Not Specified
                Not Specified
                Remaining:
                Remaining Estimate - 0 minutes
                0m
                Logged:
                Time Spent - 50 minutes
                50m