6 Commits

Author SHA1 Message Date
Eloy Lafuente (stronk7)
29a541724f
MDL-65292 style: Fix all the function declaration ordering
This has been generated running the following Sniff,
part of the Moodle's CodeSniffer standard:
- PSR2.Methods.MethodDeclaration

It just ensures all the function declarations have
the correct order for:
- abstract and final.
- visibility (public, protected, private).
- static.

So, all the lines modified by this commit are function declarations
and the only changes are in the positions of those keywords.
2024-02-28 23:47:47 +01:00
Paul Holden
58e8ad852f MDL-70823 blocks: safer unserializing during block restore. 2021-11-03 16:57:06 +01:00
Marina Glancy
9c3710854b MDL-53598 block_glossary_random: do not fail if glossary was deleted
This commit refactors how associated glossary is searched for and removes
unnecessary DB queries. Also prevents from situations when the global glossary or course have
been deleted
2016-05-31 15:30:41 +08:00
David Mudrák
32fc1a69a5 MDL-50310 glossary: Fix restore of random glossary entry block
When restoring the random glossary entry block, we need to check that
the associated glossary has also been included in the backup and is
being restored. If not, we must invalidate the block configuration.

Before this patch, the block configuration was not invalidated.

Additionally, as a result of MDL-20131, the block configuration also
contains the course id of the associated glossary (which by the way does
not seem to be a wise choice, but I may be missing something). So we
need to remap this course id as well to avoid mismatch.
2016-02-05 00:08:39 +01:00
Sam Hemelryk
f25a6839fd MDL-44120 block: tidied up block @package uses 2014-02-16 12:17:14 +13:00
Eloy Lafuente
f79e0753d4 MDL-23478 backup - Implement glossary_random & quiz_results after_restore() methods 2010-11-01 15:55:12 +00:00