Skip to content

Commit

Permalink
MDL-78425 admin: Point Clear theme caches to correct URL
Browse files Browse the repository at this point in the history
* Plus remove unnecessary call to require_once() in theme/index.php
  • Loading branch information
junpataleta committed Nov 8, 2023
1 parent 1ad8912 commit fdb78d6
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 2 deletions.
2 changes: 1 addition & 1 deletion admin/classes/output/theme_selector.php
Expand Up @@ -55,7 +55,7 @@ public function export_for_template(renderer_base $output): stdClass {
// Theme data used to populate cards and modal.
$data->themes = $this->themedata;
// Reset theme caches button.
$reseturl = new moodle_url('admin/themeselector.php', ['sesskey' => sesskey(), 'reset' => 1]);
$reseturl = new moodle_url('/admin/themeselector.php', ['sesskey' => sesskey(), 'reset' => 1]);
$resetbutton = new \single_button($reseturl, get_string('themeresetcaches', 'admin'), 'post',
\single_button::BUTTON_SECONDARY);
$data->resetbutton = $resetbutton->export_for_template($output);
Expand Down
1 change: 0 additions & 1 deletion theme/index.php
Expand Up @@ -22,7 +22,6 @@
*/

require_once(__DIR__ . '/../config.php');
require_once($CFG->libdir . '/adminlib.php');

// Theme selector has been moved to admin/themeselector.php.
redirect (new moodle_url('/admin/themeselector.php'));

0 comments on commit fdb78d6

Please sign in to comment.