Send the actual error as part of an exception response only when settings.DEBUG is enabled