fix operator precedence

This commit is contained in:
David Lord 2017-05-29 19:46:33 -07:00
parent c79abcb86c
commit 0a203d3694

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