forked from rDrama/rDrama
master
parent
06e557c61d
commit
ab729dc4d5
|
@ -23,7 +23,7 @@ beams_client = PushNotifications(
|
||||||
@auth_required
|
@auth_required
|
||||||
def suicide(v, username):
|
def suicide(v, username):
|
||||||
t = int(time.time())
|
t = int(time.time())
|
||||||
if t - v.suicide_utc < 86400: return "", 204
|
#if t - v.suicide_utc < 86400: return "", 204
|
||||||
user = get_user(username)
|
user = get_user(username)
|
||||||
suicide = f"""Hi there,
|
suicide = f"""Hi there,
|
||||||
|
|
||||||
|
@ -43,7 +43,9 @@ def suicide(v, username):
|
||||||
It may not feel like it, but you have options. There are people available to listen to you, and ways to move forward.
|
It may not feel like it, but you have options. There are people available to listen to you, and ways to move forward.
|
||||||
|
|
||||||
Your fellow dramatards care about you and there are people who want to help."""
|
Your fellow dramatards care about you and there are people who want to help."""
|
||||||
|
print(1)
|
||||||
send_notification(1046, user, suicide)
|
send_notification(1046, user, suicide)
|
||||||
|
print(2)
|
||||||
v.suicide_utc = t
|
v.suicide_utc = t
|
||||||
g.db.add(v)
|
g.db.add(v)
|
||||||
return "", 204
|
return "", 204
|
||||||
|
|
Loading…
Reference in New Issue