Fix strange float casting problems in python

This commit is contained in:
Magnus Hagander
2013-08-17 17:48:28 +02:00
parent ce499f4f0a
commit 8c21b3bd34

View File

@ -91,11 +91,11 @@ class _VersionPdfWrapper(Version):
self.a4pdf = self._find_pdf('A4')
self.uspdf = self._find_pdf('US')
# Some versions have, ahem, strange index filenames
if self.__version.tree < 6.4:
if self.__version.tree < Decimal('6.4'):
self.indexname = 'book01.htm'
elif self.__version.tree < 7.0:
elif self.__version.tree < Decimal('7.0'):
self.indexname = 'postgres.htm'
elif self.__version.tree < 7.2:
elif self.__version.tree < Decimal('7.2'):
self.indexname = 'postgres.html'
else:
self.indexname = 'index.html'