summaryrefslogtreecommitdiff
path: root/django/http
diff options
context:
space:
mode:
authorTim Graham <timograham@gmail.com>2016-03-28 18:33:29 -0400
committerTim Graham <timograham@gmail.com>2016-04-08 09:51:06 -0400
commitdf8d8d4292684d6ffa7474f1e201aed486f02b53 (patch)
treec661bf9b33de5288afe4f63347a2a9c768ef98eb /django/http
parent2956e2f5e3f63d279f5dae2a995265364d3e6db1 (diff)
Fixed E128 flake8 warnings in django/.
Diffstat (limited to 'django/http')
-rw-r--r--django/http/response.py12
1 files changed, 8 insertions, 4 deletions
diff --git a/django/http/response.py b/django/http/response.py
index da9f9ef6a6..f91a46bbbe 100644
--- a/django/http/response.py
+++ b/django/http/response.py
@@ -366,8 +366,10 @@ class StreamingHttpResponse(HttpResponseBase):
@property
def content(self):
- raise AttributeError("This %s instance has no `content` attribute. "
- "Use `streaming_content` instead." % self.__class__.__name__)
+ raise AttributeError(
+ "This %s instance has no `content` attribute. Use "
+ "`streaming_content` instead." % self.__class__.__name__
+ )
@property
def streaming_content(self):
@@ -508,8 +510,10 @@ class JsonResponse(HttpResponse):
def __init__(self, data, encoder=DjangoJSONEncoder, safe=True,
json_dumps_params=None, **kwargs):
if safe and not isinstance(data, dict):
- raise TypeError('In order to allow non-dict objects to be '
- 'serialized set the safe parameter to False')
+ raise TypeError(
+ 'In order to allow non-dict objects to be serialized set the '
+ 'safe parameter to False.'
+ )
if json_dumps_params is None:
json_dumps_params = {}
kwargs.setdefault('content_type', 'application/json')