Update error message
This commit is contained in:
parent
167eaf2a0c
commit
06b1ce9e72
1 changed files with 3 additions and 2 deletions
|
@ -1143,8 +1143,9 @@ def forbidden_view(request, exception=None, reason=''):
|
|||
Handle 403 error
|
||||
"""
|
||||
logger.error(str(exception) if exception else None)
|
||||
all_messages = messages.get_messages(request)
|
||||
messages.add_message(request, messages.ERROR, reason)
|
||||
err_msg = _('There was an error processing your request. Please try '
|
||||
'again. Details: {reason}'.format(reason=reason))
|
||||
messages.add_message(request, messages.ERROR, err_msg)
|
||||
return HttpResponseRedirect(
|
||||
request.get_full_path()
|
||||
)
|
||||
|
|
Loading…
Reference in a new issue