diff --git a/classes/local/controllers/maintenance_static_page_generator.php b/classes/local/controllers/maintenance_static_page_generator.php index d58e87b..986750a 100644 --- a/classes/local/controllers/maintenance_static_page_generator.php +++ b/classes/local/controllers/maintenance_static_page_generator.php @@ -128,7 +128,7 @@ class maintenance_static_page_generator { continue; } $saved = $this->io->save_url_file($href); - if (is_null($saved['url'])) { + if (empty($saved['url'])) { $url = $href; // Skipped, use original URL. } else { $this->update_link_stylesheet_parse($saved['file'], dirname($href)); diff --git a/classes/local/controllers/maintenance_static_page_io.php b/classes/local/controllers/maintenance_static_page_io.php index a5dbb40..eeafb53 100644 --- a/classes/local/controllers/maintenance_static_page_io.php +++ b/classes/local/controllers/maintenance_static_page_io.php @@ -213,7 +213,7 @@ class maintenance_static_page_io { /** * Saves the content of the URL into a file, returning the local filename. * @param string $url Input URL. - * @return string|null Output filename or null if skipped. + * @return array|null Output an array with the filename and url or null if skipped. */ public function save_url_file($url) { global $CFG;