-
Bug
-
Resolution: Fixed
-
Minor
-
4.2
-
MOODLE_402_STABLE
-
MOODLE_402_STABLE
-
MDL-78307-master -
This is a regression caused by MDL-76614.
In quiz locallib.php, the contexturl is set to the result of $attemptobj->view_url(). In Moodle 4.1, this function returned a string (it returned $this->quizobj->view_url(), and this function returned a string). After the refactor done in MDL-76614, the quizobj instance now returns a moodle_url instead of a string.
The contexturl supplied to message_send is supposed to be a string (or at least it was until now, and I guess it still is for all the notifications that aren't quiz related). This data is passed to Airnotifier and then to the app as a push notification. This causes problems in the app, because the app expects to receive a string but it receives an empty object instead.
There might be other places affected by this change, this is the one we noticed during our QA tests. It would be good to review all the usages of view_url to make sure it's being used as expected with the new return type.
- has been marked as being related by
-
MDL-83080 Badge notifications are sent with an object as contexturl
- Open
-
MDL-73662 404 error on quiz with browsersecurity when time finish or student click "Submit all and finish"
- Closed
- is a regression caused by
-
MDL-76614 Quiz: move all PHP classes into the classes folder - part 2
- Closed