diff options
author | Petr Viktorin <pviktori@redhat.com> | 2015-08-12 12:07:52 +0200 |
---|---|---|
committer | Jan Cholasta <jcholast@redhat.com> | 2015-09-01 11:42:01 +0200 |
commit | fbacc26a6a8b92f4b3570c411b186ab86cbcc1b1 (patch) | |
tree | 0216c07e276d4441e834a964516d2880858d4650 /ipalib/rpc.py | |
parent | c27cb295a586cdc1f1cc9b933829db471e5100ed (diff) | |
download | freeipa-fbacc26a6a8b92f4b3570c411b186ab86cbcc1b1.tar.gz freeipa-fbacc26a6a8b92f4b3570c411b186ab86cbcc1b1.tar.xz freeipa-fbacc26a6a8b92f4b3570c411b186ab86cbcc1b1.zip |
Use six.integer_types instead of (long, int)
Reviewed-By: Christian Heimes <cheimes@redhat.com>
Reviewed-By: Jan Cholasta <jcholast@redhat.com>
Diffstat (limited to 'ipalib/rpc.py')
-rw-r--r-- | ipalib/rpc.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/ipalib/rpc.py b/ipalib/rpc.py index b76d27885..dcbfafe05 100644 --- a/ipalib/rpc.py +++ b/ipalib/rpc.py @@ -166,7 +166,7 @@ def xml_wrap(value, version): if type(value) is Decimal: # transfer Decimal as a string return unicode(value) - if isinstance(value, (int, long)) and (value < MININT or value > MAXINT): + if isinstance(value, six.integer_types) and (value < MININT or value > MAXINT): return unicode(value) if isinstance(value, DN): return str(value) @@ -184,7 +184,7 @@ def xml_wrap(value, version): else: return unicode(value) - assert type(value) in (unicode, int, long, float, bool, NoneType) + assert type(value) in (unicode, float, bool, NoneType) + six.integer_types return value |