From 82bbde7c73f51fc3c305f2c0f04a2d4a8e6a39f1 Mon Sep 17 00:00:00 2001 From: mozillazg Date: Fri, 8 Jan 2016 14:49:49 +0800 Subject: [PATCH] `not x in` -> `x not in` --- httpbin/core.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/httpbin/core.py b/httpbin/core.py index 8390276..613a7c3 100644 --- a/httpbin/core.py +++ b/httpbin/core.py @@ -288,13 +288,13 @@ def stream_n_messages(n): def view_status_code(codes): """Return status code or random status code if more than one are given""" - if not ',' in codes: + if ',' not in codes: code = int(codes) return status_code(code) choices = [] for choice in codes.split(','): - if not ':' in choice: + if ':' not in choice: code = choice weight = 1 else: @@ -412,7 +412,7 @@ def digest_auth(qop=None, user='user', passwd='passwd'): qop = None if 'Authorization' not in request.headers or \ not check_digest_auth(user, passwd) or \ - not 'Cookie' in request.headers: + 'Cookie' not in request.headers: response = app.make_response('') response.status_code = 401