1
0
mirror of https://github.com/wbbaddons/Tims-Chat.git synced 2024-12-22 21:40:08 +00:00

Break if no users where found.

This commit is contained in:
Tim Düsterhus 2012-02-05 19:11:08 +01:00
parent 3ae3909b55
commit f82717d839

View File

@ -67,8 +67,11 @@ public function readUsers() {
AND fieldValue = ".intval($this->roomID); AND fieldValue = ".intval($this->roomID);
$stmt = WCF::getDB()->prepareStatement($sql); $stmt = WCF::getDB()->prepareStatement($sql);
$stmt->execute(); $stmt->execute();
$userIDs = array();
while ($row = $stmt->fetchArray()) $userIDs[] = $row['userID']; while ($row = $stmt->fetchArray()) $userIDs[] = $row['userID'];
if (!count($userIDs)) return;
$sql = "SELECT $sql = "SELECT
* *
FROM FROM