Permalink
Browse files

Merged in fix for Python 3 regarding precisions

--HG--
branch : trunk
  • Loading branch information...
2 parents c4538a8 + e589a3e commit 8e260d2f3cd20be2d05ccf3109e1178f38b9ad2c @mitsuhiko mitsuhiko committed Aug 18, 2010
Showing with 1 addition and 4 deletions.
  1. +1 −4 jinja2/filters.py
View
@@ -558,10 +558,7 @@ def do_round(value, precision=0, method='common'):
if method == 'common':
return round(value, precision)
func = getattr(math, method)
- if precision:
- return func(value * (10 ** precision)) / (10 ** precision)
- else:
- return func(value)
+ return func(value * (10 ** precision)) / (10 ** precision)
@environmentfilter

0 comments on commit 8e260d2

Please sign in to comment.