| Línea 107... |
Línea 107... |
| 107 |
* @throws restore_ui_exception for an invalid stage
|
107 |
* @throws restore_ui_exception for an invalid stage
|
| 108 |
* @param int|null $stage The desired stage to intialise or null for the default
|
108 |
* @param int|null $stage The desired stage to intialise or null for the default
|
| 109 |
* @param array $params
|
109 |
* @param array $params
|
| 110 |
* @return restore_ui_stage_initial|restore_ui_stage_schema|restore_ui_stage_confirmation|restore_ui_stage_final
|
110 |
* @return restore_ui_stage_initial|restore_ui_stage_schema|restore_ui_stage_confirmation|restore_ui_stage_final
|
| 111 |
*/
|
111 |
*/
|
| 112 |
protected function initialise_stage($stage = null, array $params = null) {
|
112 |
protected function initialise_stage($stage = null, ?array $params = null) {
|
| 113 |
if ($stage == null) {
|
113 |
if ($stage == null) {
|
| 114 |
$stage = optional_param('stage', self::STAGE_CONFIRM, PARAM_INT);
|
114 |
$stage = optional_param('stage', self::STAGE_CONFIRM, PARAM_INT);
|
| 115 |
}
|
115 |
}
|
| 116 |
$class = 'restore_ui_stage_'.self::$stages[$stage];
|
116 |
$class = 'restore_ui_stage_'.self::$stages[$stage];
|
| 117 |
if (!class_exists($class)) {
|
117 |
if (!class_exists($class)) {
|