Eloy Lafuente (stronk7) ede7105fd9 MDL-27233 move the restorer enrol/ra creation to the very beginning of the restore process
Some early steps in restore are using capability checks to decide how to
restore some information. But at that stage, if the course contents have
been removed and the user had perms at course level only (usually teacher)
the process can fail because some content is not restoreable due to the
lack of permissions.

Moving the restorer step to the beginning really helps is those situations
and it does not hurt at all.

Also, fixed one notice detected when testing this.
2011-11-25 01:07:27 +01:00
..