moodle/grade
Eloy Lafuente (stronk7) 4e2b4a138d MDL-74231 grader report: Fix case where old settings are empty / null
There is an edge case in the conversion from old collapse/expand
settings (stored as user preference) to the new ones that can lead
to notices / warnings / errors.

Before PHP 8, they weren't being detected, but now they are.

Basically, if some of the expected components of the preferences
are missing, then some array (array_diff(), array_intersect()..)
operations now are failing, because now those parameter functions
do require to be arrays (so empty strings or nulls aren't allowed).

Also, there were some cases where the old preference was not being
removed ever, so its removal has been moved to a common place at
the end of the function, where it's always evaluated in case
the preference still exists but is empty of contents.

I've tried to cover all the cases I've been able to imagine with
unit tests (empty information, some component not set, all components
not set...), have moved it to a new unit test because the one
already performing some tests with those old preferences was
already too long to add more cases.
2022-03-29 23:46:45 +02:00
..
amd MDL-73915 js: Drop support for IE and android 2022-02-23 08:55:20 +08:00
classes MDL-73824 gradebook: Stricter float check to some gradelib functions 2022-03-03 12:19:02 +01:00
edit MDL-73848 administration: Fix the breadcrumbs and nav highlights 2022-03-25 17:44:47 +08:00
export MDL-73785 phpunit: Move more tests to use correct names and namespaces 2022-03-03 12:19:30 +01:00
grading MDL-73785 phpunit: Move more tests to use correct names and namespaces 2022-03-03 12:19:30 +01:00
import MDL-73645 grades: Update breadcrumb nodes 2022-03-02 13:00:25 +08:00
report MDL-74231 grader report: Fix case where old settings are empty / null 2022-03-29 23:46:45 +02:00
templates MDL-73595 theme_boost: make tertiary nav more distinct 2022-02-28 13:07:52 +01:00
tests MDL-74231 grader report: Fix case where old settings are empty / null 2022-03-29 23:46:45 +02:00
index.php
lib.php MDL-72873 core_grades: Create method that resets all static caches 2021-12-16 00:10:13 +08:00
querylib.php MDL-63422 general: review core loop / switch / case / continue 2018-10-31 00:17:59 +01:00
renderer.php MDL-72873 core_grades: Add general tertiary navigation 2021-12-16 00:10:13 +08:00
upgrade.txt MDL-72873 core_grades: Deprecate select_in_gradebook_tabs() 2021-12-16 00:10:13 +08:00