diff --git a/WEB/Controller/EnigmeGateway.php b/WEB/Controller/EnigmeGateway.php index a1d9742b..d071859f 100644 --- a/WEB/Controller/EnigmeGateway.php +++ b/WEB/Controller/EnigmeGateway.php @@ -182,8 +182,9 @@ class EnigmeGateway public function getRandomEnigme() : Enigme { $query = "SELECT * FROM Enigme - WHERE points IS NOT NULL OR points != 0 - AND tempsDeResolution IS NOT NULL OR tempsDeResolution != 0 + WHERE points != 0 + AND tempsDeResolution != 0 + AND ordre = 0 ORDER BY RANDOM() LIMIT 1"; $this->con->executequery($query); $results = $this->con->getResults();