Clean up overboard.php to remove non-db code
This commit is contained in:
parent
abd6be4db2
commit
0e6fdb9b1c
|
@ -102,17 +102,12 @@ foreach($grouplist as $findgroup) {
|
|||
$groups = preg_split("/(\ |\t)/", $findgroup, 2);
|
||||
$findgroup = $groups[0];
|
||||
|
||||
$none=0;
|
||||
$overboard_noshow = explode(' ', $CONFIG['overboard_noshow']);
|
||||
foreach($overboard_noshow as $noshow) {
|
||||
if ((strpos($findgroup, $noshow) !== false) && !isset($_GET['thisgroup'])) {
|
||||
$none=1;
|
||||
break;
|
||||
continue 2;
|
||||
}
|
||||
}
|
||||
if($none == 1) {
|
||||
continue;
|
||||
}
|
||||
$thisgroup = preg_replace('/\./', '/', $findgroup);
|
||||
if (!is_dir($spoolpath.$thisgroup)) {
|
||||
continue;
|
||||
|
@ -122,14 +117,8 @@ foreach($grouplist as $findgroup) {
|
|||
if($dbh) {
|
||||
$query->execute(['findgroup' => $findgroup]);
|
||||
while (($overviewline = $query->fetch()) !== false) {
|
||||
if($overviewline['date'] < $oldest) {
|
||||
continue 2;
|
||||
}
|
||||
if(stripos($overviewline['newsgroup'], $findgroup) !== false) {
|
||||
$articles[] = $spoolpath.$thisgroup.'/'.$overviewline['number'];
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue