redundancy

git-svn-id: file:///home/shish/svn/shimmie2/trunk@276 7f39781d-f577-437e-ae19-be835c7a54ca
This commit is contained in:
shish 2007-07-15 17:29:05 +00:00
parent 9861e13f8e
commit d66030f35f

View file

@ -264,8 +264,7 @@ class Database {
$row = $this->db->GetRow("{$this->get_images} WHERE images.id $gtlt ? ORDER BY images.id $dir LIMIT 1", array((int)$id));
}
else {
$tags[] = ($next ? "images.id<$id" : "images.id>$id");
$dir = ($next ? "DESC" : "ASC");
$tags[] = "id$gtlt$id";
$querylet = $this->build_search_querylet($tags);
$querylet->append_sql(" ORDER BY images.id $dir LIMIT 1");
$row = $this->db->GetRow($querylet->sql, $querylet->variables);