Merge "[FileRepo] Made getDescription() respect *_deleted fields."
[lhc/web/wiklou.git] / maintenance / nextJobDB.php
index 70cfdf7..ac4e723 100644 (file)
@@ -94,11 +94,12 @@ class nextJobDB extends Maintenance {
                $lb = wfGetLB( $dbName );
                $db = $lb->getConnection( DB_MASTER, array(), $dbName );
                if ( $type === false ) {
-                       $conds = array();
+                       $conds = Job::defaultQueueConditions( );
                } else {
                        $conds = array( 'job_cmd' => $type );
                }
 
+
                $exists = (bool) $db->selectField( 'job', '1', $conds, __METHOD__ );
                $lb->reuseConnection( $db );
                return $exists;
@@ -106,7 +107,6 @@ class nextJobDB extends Maintenance {
 
        /**
         * Get all databases that have a pending job
-        * @param $type String Job type
         * @return array
         */
        private function getPendingDbs() {