Yes, although I felt that a nested if was better than:

```python
if ( spamspamspamspam and
    hamhamhamhamham
):
    pass
```
On 5 Nov 2013 19:14, "James Socol" <notifications@github.com> wrote:

> In csp/middleware.py:
>
> > @@ -14,6 +15,11 @@ class CSPMiddleware(object):
> >      """
> >
> >      def process_response(self, request, response):
> > +        # Check for debug view
> > +        if response.status_code == http_client.INTERNAL_SERVER_ERROR:
>
> Can this be an AND instead of a nested if?
>
> if (response.status_code = http_client.INTERNAL_SERVER_ERROR and
>         settings.DEBUG):
>     return response
>
> —
> Reply to this email directly or view it on GitHub<https://github.com/mozilla/django-csp/pull/34/files#r7441810>
> .
>