HaikuDepot: Show ratings in other languages with empty comments

This commit is contained in:
Stephan Aßmus 2014-10-25 16:31:08 +02:00
parent 7102f0d09b
commit 9303787b1a

View File

@ -1265,7 +1265,10 @@ public:
// TODO: Sort by age or usefullness rating
for (int i = count - 1; i >= 0; i--) {
const UserRating& rating = userRatings.ItemAtFast(i);
if (fPreferredLanguages.CountItems() > 0
// Prevent ratings from showing that have a comment which
// is in another language
if (!rating.Comment().IsEmpty()
&& fPreferredLanguages.CountItems() > 0
&& !fPreferredLanguages.Contains(rating.Language())) {
continue;
}