Skip to content

Commit

Permalink
Fixed the import() function parameters issue.
Browse files Browse the repository at this point in the history
  • Loading branch information
Nithy1anand committed Jun 17, 2023
1 parent b0ac8d4 commit 69d0851
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
5 changes: 2 additions & 3 deletions classes/course_importer.php
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ public static function import_from_template($templateid, $courseid) {
$backuptempdir = make_backup_temp_directory('template' . $templateid);
$files[0]->extract_to_pathname($fp, $backuptempdir);

self::import('template' . $templateid, $courseid, $templateid);
self::import('template' . $templateid, $courseid);
} else {
$course = (array) $DB->get_record('course', array('id' => $courseid));
$course['format'] = $template->format;
Expand Down Expand Up @@ -106,13 +106,12 @@ public static function import_from_template($templateid, $courseid) {
*
* @param string $backuptempdir
* @param int $courseid
* @param int $templateid
* @throws \base_plan_exception
* @throws \base_setting_exception
* @throws \dml_exception
* @throws \restore_controller_exception
*/
public static function import($backuptempdir, $courseid, $templateid) {
public static function import($backuptempdir, $courseid) {
global $USER, $DB;

$course = $DB->get_record('course', ['id' => $courseid]);
Expand Down
2 changes: 1 addition & 1 deletion version.php
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@

defined('MOODLE_INTERNAL') || die();

$plugin->version = 2023050801; // The current plugin version (Date: YYYYMMDDXX).
$plugin->version = 2023061700; // The current plugin version (Date: YYYYMMDDXX).
$plugin->requires = 2022041900; // Requires this Moodle version.
$plugin->release = 'Version 1.3';
$plugin->component = 'format_kickstart'; // Full name of the plugin (used for diagnostics).
Expand Down

0 comments on commit 69d0851

Please sign in to comment.