From e58b8211e0279cb5a16e41933642624bd8fce636 Mon Sep 17 00:00:00 2001 From: Julio Montoya Date: Fri, 20 Jul 2012 15:28:33 +0200 Subject: [PATCH] Fixes PHP warnings --- main/newscorm/learnpath.class.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/main/newscorm/learnpath.class.php b/main/newscorm/learnpath.class.php index 2cde6ba110..bb8bcf4255 100644 --- a/main/newscorm/learnpath.class.php +++ b/main/newscorm/learnpath.class.php @@ -8837,8 +8837,9 @@ class learnpath { //Add files inside the HTMLs $new_path = str_replace('/courses/', '', $old_new['orig']); //var_dump($sys_course_path.$new_path); var_dump($archive_path.$temp_dir_short.'/'.$old_new['dest']); echo '---'; - copy($sys_course_path.$new_path, $archive_path.$temp_dir_short.'/'.$old_new['dest']); - + if (file_exists($sys_course_path.$new_path)) { + copy($sys_course_path.$new_path, $archive_path.$temp_dir_short.'/'.$old_new['dest']); + } } file_put_contents($dest_file, $string); }