fetch_assoc()) { extract($q); if(getsql("select 1 from Responses where quest=$quest", 'used?')) continue; // unindexed sql("delete from Questions where quest=$quest"); sql("delete from QuestionKey where quest=$quest"); } $qid->free(); // NOTIFY BUGS $foolbugs = getsql("select count(*) from Foolacy.Bugs where status='new' && date>='$nightly 00:00:00'", 'New bugs?'); $factbugs = getsql("select count(*) from FactOpy.Bugs where status='new' && date>='$nightly 00:00:00'", 'New bugs?'); $thinkbugs = getsql("select count(*) from ThinkKeen.Bugs where status='new' && date>='$nightly 00:00:00'", 'New bugs?'); $totalbugs=$foolbugs+$factbugs+$thinkbugs; if($totalbugs) { $toemail='dhundsness@gmail.com'; $subject="$totalbugs Bugs"; if(!$live) $subject.=" (dev)"; $html="$nightly to $now recent bugs:"; if($foolbugs) $html.="
$foolbugs Foolacy"; if($factbugs) $html.="
$factbugs FactOpy"; if($thinkbugs) $html.="
$thinkbugs ThinkKeen"; if($live) mailit($toemail,$subject,$html); else logit("mail $toemail\n$subject\n$html"); } ?>