Bugfix: s/CRC32//

This commit is contained in:
Michael Save 2012-04-19 01:38:35 +10:00
parent 931c2d679e
commit 163c11d001

View File

@ -248,7 +248,7 @@ function checkSpam(array $extra_salt = array()) {
if ($hash != $_hash)
return true;
$query = prepare('UPDATE `antispam` SET `passed` = `passed` + 1 WHERE `hash` = CRC32(:hash)');
$query = prepare('UPDATE `antispam` SET `passed` = `passed` + 1 WHERE `hash` = :hash');
$query->bindValue(':hash', $hash);
$query->execute() or error(db_error($query));
if ($query->rowCount() == 0) {
@ -256,7 +256,7 @@ function checkSpam(array $extra_salt = array()) {
return true;
}
$query = prepare('SELECT `passed` FROM `antispam` WHERE `hash` = CRC32(:hash)');
$query = prepare('SELECT `passed` FROM `antispam` WHERE `hash` = :hash');
$query->bindValue(':hash', $hash);
$query->execute() or error(db_error($query));
$passed = $query->fetchColumn(0);