forked from GithubBackups/healthchecks
Unsubscribe is CSRF exempt.
This commit is contained in:
parent
f9c61dad23
commit
4ee92a44ff
@ -701,6 +701,7 @@ def verify_email(request, code, token):
|
|||||||
return render(request, "bad_link.html")
|
return render(request, "bad_link.html")
|
||||||
|
|
||||||
|
|
||||||
|
@csrf_exempt
|
||||||
def unsubscribe_email(request, code, token):
|
def unsubscribe_email(request, code, token):
|
||||||
channel = get_object_or_404(Channel, code=code)
|
channel = get_object_or_404(Channel, code=code)
|
||||||
if channel.make_token() != token:
|
if channel.make_token() != token:
|
||||||
|
@ -6,7 +6,6 @@
|
|||||||
<p>Please press the button below to unsubscribe:</p>
|
<p>Please press the button below to unsubscribe:</p>
|
||||||
<br />
|
<br />
|
||||||
<form id="form" method="post">
|
<form id="form" method="post">
|
||||||
{% csrf_token %}
|
|
||||||
<input
|
<input
|
||||||
id="submit-btn"
|
id="submit-btn"
|
||||||
type="submit"
|
type="submit"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user