Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mapsme/omim.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/map
diff options
context:
space:
mode:
authorArsentiy Milchakov <milcars@mapswithme.com>2018-08-29 11:18:34 +0300
committerRoman Kuznetsov <r.kuznetsow@gmail.com>2018-08-29 11:29:16 +0300
commitf864d990e10fdefdf49cd125546b6e27a00b3149 (patch)
treee68707c8436ad7436d55a23d5cce55cb0767fca9 /map
parentf0162b029eb90bd5dafc6799ca86e48d472a8b94 (diff)
fix for zero rating
Diffstat (limited to 'map')
-rw-r--r--map/place_page_info.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/map/place_page_info.cpp b/map/place_page_info.cpp
index 33e834d4ca..453b6f671b 100644
--- a/map/place_page_info.cpp
+++ b/map/place_page_info.cpp
@@ -357,7 +357,7 @@ Impress GetImpress(float const rawRating)
CHECK_LESS_OR_EQUAL(rawRating, kTopRatingBound, ());
CHECK_GREATER_OR_EQUAL(rawRating, kIncorrectRating, ());
- if (rawRating == kIncorrectRating)
+ if (rawRating <= 0.0f)
return Impress::None;
if (rawRating < 0.2f * kTopRatingBound)
return Impress::Horrible;
@@ -376,7 +376,7 @@ std::string GetRatingFormatted(float const rawRating)
CHECK_LESS_OR_EQUAL(rawRating, kTopRatingBound, ());
CHECK_GREATER_OR_EQUAL(rawRating, kIncorrectRating, ());
- if (rawRating == kIncorrectRating)
+ if (rawRating <= 0.0f)
return kEmptyRatingSymbol;
std::ostringstream oss;