From ed6f334f5ff8900c9fdde15dbebb5a5668213ab2 Mon Sep 17 00:00:00 2001 From: Ondrej Chmelar Date: Fri, 5 Apr 2019 12:38:04 +0200 Subject: [PATCH] =?UTF-8?q?fix=20a=206=20years=20old=20issue=20?= =?UTF-8?q?=F0=9F=A4=A6=E2=80=8Dhttps://github.com/pinax/pinax-notificatio?= =?UTF-8?q?ns/issues/21?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pinax/notifications/hooks.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pinax/notifications/hooks.py b/pinax/notifications/hooks.py index 38f050e9..d215b121 100644 --- a/pinax/notifications/hooks.py +++ b/pinax/notifications/hooks.py @@ -33,7 +33,7 @@ def notice_setting_for_user(self, user, notice_type, medium, scoping=None): "scoping_content_type": None, "scoping_object_id": None }) - default = (NOTICE_MEDIA_DEFAULTS[medium] <= notice_type.default) + default = (NOTICE_MEDIA_DEFAULTS[str(medium)] <= notice_type.default) kwargs.update({"send": default}) setting = user.noticesetting_set.create(**kwargs) return setting