From de2cb5fede0766a52717024615cc56a03465fe61 Mon Sep 17 00:00:00 2001 From: Claude Paroz Date: Wed, 15 Aug 2012 13:27:40 +0200 Subject: [PATCH] [py3] Fixed F-expression right-hand division Complementary to commit 62a9ed0ac. --- django/db/models/expressions.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/django/db/models/expressions.py b/django/db/models/expressions.py index eb5e7d6fd9..639ef6ee10 100644 --- a/django/db/models/expressions.py +++ b/django/db/models/expressions.py @@ -80,8 +80,9 @@ class ExpressionNode(tree.Node): def __rmul__(self, other): return self._combine(other, self.MUL, True) - def __rdiv__(self, other): + def __rtruediv__(self, other): return self._combine(other, self.DIV, True) + __rdiv__ = __rtruediv__ # Python 2 compatibility def __rmod__(self, other): return self._combine(other, self.MOD, True)