Safer comparison

This commit is contained in:
Juan Ignacio Sánchez Lara 2018-07-17 12:27:42 +02:00
parent e2762a6e03
commit e9ed3bca18

View File

@ -99,7 +99,7 @@ class MapboxGeocoder(Traceable):
}
def _normalize_relevance(self, relevance):
return 1 if relevance == 0.99 else relevance
return 1 if relevance >= 0.99 else relevance
def _validate_input(self, searchtext, city=None, state_province=None,
country=None):