fix operator precedence

This commit is contained in:
David Lord 2017-05-29 19:46:33 -07:00
parent 42905b8a55
commit 8f3563cf79
No known key found for this signature in database
GPG key ID: 7A1C87E3F5BC42A8

View file

@ -1585,7 +1585,7 @@ class Flask(_PackageBoundObject):
# when generating the response message. Set an informative
# description for key errors in debug mode or when trapping errors.
if (
self.debug or self.config['TRAP_BAD_REQUEST_ERRORS']
(self.debug or self.config['TRAP_BAD_REQUEST_ERRORS'])
and isinstance(e, BadRequestKeyError)
# only set it if it's still the default description
and e.description is BadRequestKeyError.description