Notify.php
authorAlan Knowles <alan@akbkhome.com>
Thu, 11 Aug 2011 03:07:09 +0000 (11:07 +0800)
committerAlan Knowles <alan@akbkhome.com>
Thu, 11 Aug 2011 03:07:09 +0000 (11:07 +0800)
Notify.php

index e1fcd07..6ad652f 100644 (file)
@@ -86,15 +86,17 @@ class Pman_Core_Notify extends Pman
             $w->whereAdd('act_when < NOW()'); // eg.. not if future..
     
             $w->orderBy('act_when ASC'); // oldest first.
+            $w->limit(1000); // we can run 1000 ...
         } else {
             $w->orderBy('act_when DESC'); // latest first
+            $w->limit(50); // we can run 1000 ...
         }
         if (!empty($this->evtype)) {
             $w->evtype = $this->evtype;
         }
         
         $w->autoJoin();
-        $w->limit(1000); // we can run 1000 ...
+        
         
         $ar = $w->fetchAll();