MDL-24759 fixing incorrect skipping on non-url file type resources, credit goes to...
authorPetr Skoda <skodak@moodle.org>
Tue, 19 Oct 2010 07:46:26 +0000 (07:46 +0000)
committerPetr Skoda <skodak@moodle.org>
Tue, 19 Oct 2010 07:46:26 +0000 (07:46 +0000)
mod/url/db/upgradelib.php

index c47b733..8ff7adc 100644 (file)
@@ -63,13 +63,13 @@ function url_20_migrate() {
             continue;
         } else if (!strpos($path, '://')) {
             // not URL
             continue;
         } else if (!strpos($path, '://')) {
             // not URL
-            return;
+            continue;
         } else if (preg_match("|$CFG->wwwroot/file.php(\?file=)?/$siteid(/[^\s'\"&\?#]+)|", $path, $matches)) {
             // handled by resource module
         } else if (preg_match("|$CFG->wwwroot/file.php(\?file=)?/$siteid(/[^\s'\"&\?#]+)|", $path, $matches)) {
             // handled by resource module
-            return;
+            continue;
         } else if (preg_match("|$CFG->wwwroot/file.php(\?file=)?/$candidate->course(/[^\s'\"&\?#]+)|", $path, $matches)) {
             // handled by resource module
         } else if (preg_match("|$CFG->wwwroot/file.php(\?file=)?/$candidate->course(/[^\s'\"&\?#]+)|", $path, $matches)) {
             // handled by resource module
-            return;
+            continue;
         }
 
         upgrade_set_timeout();
         }
 
         upgrade_set_timeout();