[FIX] *: leftover invalid uses of pycompat

This commit is contained in:
Christophe Simonis
2017-08-24 13:43:19 +02:00
parent 017ee5eab3
commit 4837f4ef17
2 changed files with 2 additions and 2 deletions
+1 -1
View File
@@ -209,7 +209,7 @@ class IrHttp(models.AbstractModel):
@classmethod
def _postprocess_args(cls, arguments, rule):
""" post process arg to set uid on browse records """
for key, val in list(pycompat.items(arguments)):
for key, val in list(arguments.items()):
# Replace uid placeholder by the current request.uid
if isinstance(val, models.BaseModel) and isinstance(val._uid, RequestUID):
arguments[key] = val.sudo(request.uid)
+1 -1
View File
@@ -77,7 +77,7 @@ def float_round(value, precision_digits=None, precision_rounding=None, rounding_
epsilon = 2**(epsilon_magnitude-53)
if rounding_method == 'HALF-UP':
normalized_value += math.copysign(epsilon, normalized_value)
rounded_value = pycompat.round(normalized_value) # round to integer
rounded_value = round(normalized_value) # round to integer
# TIE-BREAKING: UP (for ceiling operations)
# When rounding the value up, we instead subtract the epsilon value