diff options
author | Jason R. Coombs <jaraco@jaraco.com> | 2017-10-29 13:35:41 -0400 |
---|---|---|
committer | Jason R. Coombs <jaraco@jaraco.com> | 2017-10-29 13:35:41 -0400 |
commit | 82d2bcfa63c8997eed677c6b2d0b8d53820f691f (patch) | |
tree | 5de869228357dedb4a434a834b410d003497b55a | |
parent | 6a204c88cf605dc4f4a6b87ebe421d5f8bd6c515 (diff) | |
download | cherrypy-git-82d2bcfa63c8997eed677c6b2d0b8d53820f691f.tar.gz |
Get cmp from builtins
-rw-r--r-- | cherrypy/lib/httputil.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/cherrypy/lib/httputil.py b/cherrypy/lib/httputil.py index 78c4bae3..074c80b7 100644 --- a/cherrypy/lib/httputil.py +++ b/cherrypy/lib/httputil.py @@ -15,7 +15,7 @@ from cgi import parse_header from email.header import decode_header import six -from six.moves import range +from six.moves import range, builtins from six.moves.BaseHTTPServer import BaseHTTPRequestHandler from cherrypy._cpcompat import ntob, ntou @@ -137,7 +137,7 @@ class HeaderElement(object): self.params = params def __cmp__(self, other): - return cmp(self.value, other.value) # noqa: F821 + return builtins.cmp(self.value, other.value) def __lt__(self, other): return self.value < other.value @@ -205,9 +205,9 @@ class AcceptElement(HeaderElement): return float(val) def __cmp__(self, other): - diff = cmp(self.qvalue, other.qvalue) # noqa: F821 + diff = builtins.cmp(self.qvalue, other.qvalue) if diff == 0: - diff = cmp(str(self), str(other)) # noqa: F821 + diff = builtins.cmp(str(self), str(other)) return diff def __lt__(self, other): |