From: moodler Date: Fri, 25 Jul 2003 08:19:33 +0000 (+0000) Subject: FIxed the LIMIT bug I just made ... need to find a better way X-Git-Url: http://git.mjollnir.org/gw?a=commitdiff_plain;h=30e72d4227f130b4dd56edc970fde438c8d660be;p=moodle.git FIxed the LIMIT bug I just made ... need to find a better way as this sets off get_record alarms --- diff --git a/mod/chat/lib.php b/mod/chat/lib.php index a0c80f4213..a875d435b3 100644 --- a/mod/chat/lib.php +++ b/mod/chat/lib.php @@ -186,10 +186,10 @@ function chat_get_latest_message($chatid) { global $CFG; - return get_record_sql("SELECT * + return get_record_sql("SELECT * FROM {$CFG->prefix}chat_messages WHERE chatid = '$chatid' - ORDER BY timestamp DESC LIMIT 1"); + ORDER BY timestamp DESC"); } //////////////////////////////////////////////////////////////////////