The histogram was independently querying the reviews table, and, as a result, it was failing to exclude reviews where reviews.special is non-null.
You can mark a review as "special" by editing the review with a "Special Review Type," which can be either "From the Author" or "External."
In fact, the entire histogram query is unnecessary, because we store this data in the gameRatings materialized view, specifically designed for fast lookup, so I've replaced the histogram query with data pulled from the view.
Fixes https://github.com/iftechfoundation/ifdb/issues/408
The histogram was independently querying the reviews table, and, as a result, it was failing to exclude reviews where
reviews.special
is non-null.You can mark a review as "special" by editing the review with a "Special Review Type," which can be either "From the Author" or "External."
In fact, the entire histogram query is unnecessary, because we store this data in the gameRatings materialized view, specifically designed for fast lookup, so I've replaced the histogram query with data pulled from the view.