only optimise this case for regular tags

This commit is contained in:
Shish 2010-02-03 21:58:01 +00:00
parent ca8fc63bf2
commit 937a430a50

View File

@ -140,7 +140,7 @@ class Image {
} }
return $total; return $total;
} }
else if(count($tags) == 1) { else if(count($tags) == 1 && !preg_match("/[:=><]/", $tags[0])) {
return $database->db->GetOne( return $database->db->GetOne(
$database->engine->scoreql_to_sql("SELECT count FROM tags WHERE SCORE_STRNORM(tag) = SCORE_STRNORM(?)"), $database->engine->scoreql_to_sql("SELECT count FROM tags WHERE SCORE_STRNORM(tag) = SCORE_STRNORM(?)"),
$tags); $tags);