Merge news and email search results
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
SELECT
|
||||
site,
|
||||
date,
|
||||
is_read,
|
||||
title,
|
||||
@@ -8,7 +9,7 @@ FROM
|
||||
post p
|
||||
JOIN feed f ON p.site = f.slug
|
||||
WHERE
|
||||
site = $1
|
||||
($1::text IS NULL OR site = $1)
|
||||
AND (
|
||||
NOT $2
|
||||
OR NOT is_read
|
||||
|
||||
Reference in New Issue
Block a user