Skip to content

Commit

Permalink
Fix getSmurfs.php
Browse files Browse the repository at this point in the history
  • Loading branch information
AsteroidusTv committed Jul 26, 2024
1 parent 77650e6 commit e76a7fd
Showing 1 changed file with 0 additions and 11 deletions.
11 changes: 0 additions & 11 deletions api/getSmurfs.php
Original file line number Diff line number Diff line change
Expand Up @@ -26,16 +26,6 @@ function compareSmurfs($a, $b, $sort)


if (isset($searchQuery)) {
<<<<<<< HEAD:api/getSmurfs.php
$Smurfs = $db->select("SELECT * FROM gargameleaks_comments_teachers WHERE name LIKE '%$searchQuery%' ORDER BY name");
} else {
$Smurfs = $db->select("SELECT * FROM gargameleaks_comments_teachers ORDER BY name");
}

foreach ($Smurfs as &$teacher) {
$comments = $db->select("SELECT * FROM gargameleaks_comments_comments WHERE teacher_ID = '{$teacher["ID"]}'");
$votesData = $db->select("SELECT * FROM gargameleaks_comments_votes WHERE teacher_ID = '{$teacher["ID"]}'");
=======
$teachers = $db->select("SELECT * FROM gargameleaks_teachers WHERE name LIKE '%$searchQuery%' ORDER BY name");
} else {
$teachers = $db->select("SELECT * FROM gargameleaks_teachers ORDER BY name");
Expand All @@ -44,7 +34,6 @@ function compareSmurfs($a, $b, $sort)
foreach ($teachers as &$teacher) {
$comments = $db->select("SELECT * FROM gargameleaks_comments WHERE teacher_ID = '{$teacher["ID"]}'");
$votesData = $db->select("SELECT * FROM gargameleaks_votes WHERE teacher_ID = '{$teacher["ID"]}'");
>>>>>>> 1a56928bc55611875d70be6a628d0a91516e988f:api/getTeachers.php
$votesCount = count($votesData);

$teachingQualityTotal = 0;
Expand Down

0 comments on commit e76a7fd

Please sign in to comment.