Skip to content

Commit

Permalink
py3 fix
Browse files Browse the repository at this point in the history
  • Loading branch information
jbrockmendel committed Jan 23, 2018
1 parent 84c74c5 commit 06df02a
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion pandas/core/indexes/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -4186,7 +4186,8 @@ def dispatch_missing(op, left, right, result):
result : ndarray
"""
opstr = '__{opname}__'.format(opname=op.__name__).replace('____', '__')
if op in [operator.div, operator.truediv, operator.floordiv]:
if op in [operator.truediv, operator.floordiv,
getattr(operator, 'div', None)]:
result = missing.mask_zero_div_zero(left, right, result)
elif op is operator.mod:
result = missing.fill_zeros(result, left, right,
Expand Down

0 comments on commit 06df02a

Please sign in to comment.