From 03935729557951d2481f38946d3d2d1edbbe2fe8 Mon Sep 17 00:00:00 2001 From: Junchuan Zhang Date: Fri, 25 Sep 2020 14:43:16 +0800 Subject: [PATCH] Update decorators.rst Tested: python 3.5 --- decorators.rst | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/decorators.rst b/decorators.rst index 30509fe..424568b 100644 --- a/decorators.rst +++ b/decorators.rst @@ -440,9 +440,9 @@ will not be covered here). A logit implementation for sending emails to admins when the function is called. ''' - def __init__(self, email='admin@myproject.com', *args, **kwargs): + def __init__(self, func, email='admin@myproject.com', *args, **kwargs): self.email = email - super(email_logit, self).__init__(*args, **kwargs) + super(email_logit, self).__init__(func, *args, **kwargs) def notify(self): # Send an email to self.email