1
0
mirror of https://github.com/django/django.git synced 2025-10-24 06:06:09 +00:00

Fixed #22407 -- Added AdminEmailHandler.send_mail().

This commit is contained in:
Berker Peksag
2014-11-10 23:21:31 +02:00
committed by Tim Graham
parent a305695f28
commit d552da1f8d
4 changed files with 38 additions and 6 deletions

View File

@@ -271,6 +271,13 @@ Internationalization
reusable apps. It also allows overriding those custom formats in your main
Django project.
Logging
^^^^^^^
* The :class:`django.utils.log.AdminEmailHandler` class now has a
:meth:`~django.utils.log.AdminEmailHandler.send_mail` method to make it more
subclass friendly.
Management Commands
^^^^^^^^^^^^^^^^^^^

View File

@@ -563,8 +563,15 @@ Python logging module.
By default, an instance of the email backend specified in
:setting:`EMAIL_BACKEND` will be used.
.. _Sentry: https://pypi.python.org/pypi/sentry
.. method:: send_mail(subject, message, *args, **kwargs)
.. versionadded:: 1.8
Sends emails to admin users. To customize this behavior, you can
subclass the :class:`~django.utils.log.AdminEmailHandler` class and
override this method.
.. _Sentry: https://pypi.python.org/pypi/sentry
Filters
-------