This website works better with JavaScript.
Home
Explore
Help
Register
Sign In
nielsperetzke
/
healthchecks
Watch
1
Star
0
Fork
0
Code
Issues
0
Pull Requests
0
Projects
0
Releases
32
Wiki
Activity
Browse Source
Unsubscribe is CSRF exempt.
pull/313/head
Pēteris Caune
5 years ago
parent
f9c61dad23
commit
4ee92a44ff
No known key found for this signature in database
GPG Key ID:
E28D7679E9A9EDE2
2 changed files
with
1 additions
and
1 deletions
Split View
Diff Options
Show Stats
Download Patch File
Download Diff File
+1
-0
hc/front/views.py
+0
-1
templates/accounts/unsubscribe_submit.html
+ 1
- 0
hc/front/views.py
View File
@ -701,6 +701,7 @@ def verify_email(request, code, token):
return
render
(
request
,
"
bad_link.html
"
)
@csrf_exempt
def
unsubscribe_email
(
request
,
code
,
token
)
:
channel
=
get_object_or_404
(
Channel
,
code
=
code
)
if
channel
.
make_token
(
)
!=
token
:
+ 0
- 1
templates/accounts/unsubscribe_submit.html
View File
@ -6,7 +6,6 @@
<
p
>
Please press the button below to unsubscribe:
<
/
p
>
<
br
/
>
<
form
id
=
"form"
method
=
"post"
>
{% csrf_token %}
<
input
id="submit-btn"
type="submit"
Write
Preview
Loading…
Cancel
Save