From b9c56b98550a14265195bff97ffff99c057d119a Mon Sep 17 00:00:00 2001 From: Victoria <74339421+Ruixi-Zhang@users.noreply.github.com> Date: Fri, 29 Apr 2022 13:44:05 -0400 Subject: [PATCH] Update views.py fix issue 1 --- mail/views.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/mail/views.py b/mail/views.py index 5b344af..290ca0f 100644 --- a/mail/views.py +++ b/mail/views.py @@ -62,7 +62,7 @@ def compose(request): sender=request.user, subject=subject, body=body, - read=user == request.user + read=False ) email.save() for recipient in recipients: @@ -176,4 +176,4 @@ def register(request): login(request, user) return HttpResponseRedirect(reverse("index")) else: - return render(request, "mail/register.html") \ No newline at end of file + return render(request, "mail/register.html")