brack3t/django-braces — pull request #145 by blueyed (2014-08-09 14:07:51+00:00)
Title: TBD: access mixins: support for custom exceptions

I wanted to use a custom exception with `SuperuserRequiredMixin` (`Http404`) and added support for it.

`raise_exception` can now be `True`, `False`, a custom exception or a callable (that should return a response).

I have then factored the no-permission handling into a separate function, and moved `redirect_unauthenticated_users` to the base mixin.

This does not include any documentation changes yet, because I wanted to gather feedback on it first.