# This patch file was generated by NetBeans IDE
# This patch can be applied using context Tools: Apply Diff Patch action on respective folder.
# It uses platform neutral UTF-8 encoding.
# Above lines and this line are ignored by the patching process.
Index: moodle/lib/datalib.php
--- moodle/lib/datalib.php Base (1.439.2.35)
+++ moodle/lib/datalib.php Locally Modified (Based On 1.439.2.35)
@@ -1343,7 +1343,7 @@
     // $mustshift indicates whether the sequence must be shifted to
     // meet its range
     $mustshift = false;
-    if ($min < $n+$tolerance || $min > $n+$tolerance+$catgap ) {
+    if ($min < $n-$tolerance || $min > $n+$tolerance+$catgap ) {
         $mustshift = true;
     }
 
