When loading a course, an HTTP request is triggered for the course's header image. However, this request is made without a token, so the request fails, and triggers an exception in webservice/pluginfile.php. This occurs even when using a custom course format. We are seeing the following in our PHP logs as a result:
Step to reproduce:
- Visit https://mobileapp.moodledemo.net/ in chrome
- Enter https://school.demo.moodle.net/ and log in as "student", password "moodle"
- Click on Dashboard, and select the "Celebrating cultures" course.
- Press F12 to open developer tools. Switch to the Network tab and clear the log.
- Pull to refresh.
- You will see a failed request for https://school.demo.moodle.net/webservice/pluginfile.php/1033/course/overviewfiles/diversity.jpg. Note that the URL does not include the web service token.