From 3aea2b51e9bac7859a8a84361a1f5521934d078c Mon Sep 17 00:00:00 2001 From: Julio Montoya Date: Wed, 21 Nov 2012 13:38:40 +0100 Subject: [PATCH] Minor cleaning files --- main/newscorm/lp_ajax_switch_item_toc.php | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/main/newscorm/lp_ajax_switch_item_toc.php b/main/newscorm/lp_ajax_switch_item_toc.php index 9437fccb87..a2005e98d6 100644 --- a/main/newscorm/lp_ajax_switch_item_toc.php +++ b/main/newscorm/lp_ajax_switch_item_toc.php @@ -45,7 +45,7 @@ function switch_item_toc($lp_id, $user_id, $view_id, $current_item, $next_item) if ($debug > 2) { error_log('Building new lp', 0); } unset($oLP); $code = api_get_course_id(); - $mylp = new learnpath($code,$lp_id,$user_id); + $mylp = new learnpath($code, $lp_id, $user_id); } else { if ($debug > 1) { error_log('Reusing session lp', 0); } $mylp = & $oLP; @@ -87,8 +87,7 @@ function switch_item_toc($lp_id, $user_id, $view_id, $current_item, $next_item) $mylp->start_current_item(true); if ($mylp->force_commit) { $mylp->save_current(); - } - //$objResponse->addAlert(api_get_path(REL_CODE_PATH).'newscorm/learnpathItem.class.php'); + } if (is_object($mylp->items[$new_item_id])) { $mylpi = & $mylp->items[$new_item_id]; } else { @@ -182,8 +181,6 @@ function switch_item_toc($lp_id, $user_id, $view_id, $current_item, $next_item) if ($debug > 1) { error_log('Prereq_match() returned '.htmlentities($mylp->error), 0); } $_SESSION['scorm_item_id'] = $new_item_id; // Save the new item ID for the exercise tool to use. $_SESSION['lpobject'] = serialize($mylp); - return $return; - //return $objResponse; + return $return; } - -echo switch_item_toc($_POST['lid'], $_POST['uid'], $_POST['vid'], $_POST['iid'], $_POST['next']); +echo switch_item_toc($_POST['lid'], $_POST['uid'], $_POST['vid'], $_POST['iid'], $_POST['next']); \ No newline at end of file