From c94cb4f86541d8f76ee27652e214fedd0c0920fe Mon Sep 17 00:00:00 2001 From: Mads Jensen Date: Wed, 25 Jan 2017 15:14:05 +0100 Subject: [1.11.x] Removed unused variables that are overwritten. Backport of ebf34c3cdcd2c75349c60a064427ac255958bf9b from master --- django/http/multipartparser.py | 4 ---- 1 file changed, 4 deletions(-) (limited to 'django/http/multipartparser.py') diff --git a/django/http/multipartparser.py b/django/http/multipartparser.py index 616185f021..cf82e3851e 100644 --- a/django/http/multipartparser.py +++ b/django/http/multipartparser.py @@ -578,15 +578,11 @@ def exhaust(stream_or_iterable): Raise a MultiPartParserError if the argument is not a stream or an iterable. """ - iterator = None try: iterator = iter(stream_or_iterable) except TypeError: iterator = ChunkIter(stream_or_iterable, 16384) - if iterator is None: - raise MultiPartParserError('multipartparser.exhaust() was passed a non-iterable or stream parameter') - for __ in iterator: pass -- cgit v1.3