From bda4e1ef0906386efa0f4a05b9b537061da7c50b Mon Sep 17 00:00:00 2001 From: Markus Heck <51326311+Glutamat42@users.noreply.github.com> Date: Fri, 20 Sep 2024 21:35:38 +0200 Subject: [PATCH] fix upgrade.php (#30) fix --- db/upgrade.php | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/db/upgrade.php b/db/upgrade.php index 7a04fa4..4a16717 100644 --- a/db/upgrade.php +++ b/db/upgrade.php @@ -11,8 +11,6 @@ function xmldb_local_adler_upgrade($oldversion): bool { // $dbman = $DB->get_manager(); // Loads ddl manager and xmldb classes. if ($oldversion < 2024090900) { - $success = true; - try { $courses = get_courses('all'); foreach ($courses as $course) { if ($course->id == 1) { @@ -26,16 +24,12 @@ function xmldb_local_adler_upgrade($oldversion): bool { // Do nothing } } - } catch (moodle_exception $e) { -// $success = false; - throw $e; - } // Logging the upgrade. - upgrade_plugin_savepoint($success, 2024090900, 'local', 'adler'); + upgrade_plugin_savepoint(true, 2024090900, 'local', 'adler'); } // Everything has succeeded to here. Return true. return true; -} \ No newline at end of file +}