Skip to content

Commit

Permalink
Merge pull request #1062 from PaulBender/fix-1061
Browse files Browse the repository at this point in the history
Fixes #1061 SQL error when searching for "posts with this ip"
  • Loading branch information
Destroy666x committed Aug 2, 2014
2 parents 1d56ee4 + 9c80afa commit 4466e4d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions modcp.php
Original file line number Diff line number Diff line change
Expand Up @@ -3582,7 +3582,7 @@
$query = $db->query("
SELECT COUNT(pid) AS count
FROM ".TABLE_PREFIX."posts
WHERE {$post_ip_sql} AND visibility >= -1
WHERE {$post_ip_sql} AND visible >= -1
");

$post_results = $db->fetch_field($query, "count");
Expand Down Expand Up @@ -3737,7 +3737,7 @@
$query = $db->query("
SELECT username AS postusername, uid, subject, pid, tid, ipaddress
FROM ".TABLE_PREFIX."posts
WHERE {$post_ip_sql} AND visibility >= -1
WHERE {$post_ip_sql} AND visible >= -1
ORDER BY dateline DESC
LIMIT {$post_start}, {$post_limit}
");
Expand Down

0 comments on commit 4466e4d

Please sign in to comment.