@@ -75,25 +75,25 @@ if (!$school['crawled']) {
$dept_strlen = strlen($term_parts['department']);
$dept = $term_parts['department'];
if (!$getsections && count($term_parts) == 1 && $term_strlen == strlen($dept))
{
$dept_file = $cache_dir . '-depts';
if (!file_exists($dept_file)) {
clean_empty_exit();
}
$departments = unserialize(file_get_contents($dept_file));
$json_depts = array();
foreach ($departments as $key => $department) {
if (!strncmp($department, $dept, $dept_strlen)) {
$json_depts[] = $department . "-";
$json_depts[] = $department . '-';
echo json_encode($json_depts);
exit(0);
if ($getsections)
$section_file = $cache_dir . $dept . DIRECTORY_SEPARATOR . $term_parts['course'];
if (file_exists($section_file))
Status change: