Add user post deletion
Users can delete their posts as long as they don't clear their cookies, and as long as server-side user sessions are persistent. Signed-off-by: Alek Ratzloff <alekratz@gmail.com>
This commit is contained in:
@@ -124,6 +124,10 @@ class Post(models.Model):
|
||||
# Image width and height
|
||||
image_width = models.IntegerField(null=True, blank=True)
|
||||
image_height = models.IntegerField(null=True, blank=True)
|
||||
# The user token that was used to make this post. This is used for
|
||||
# verification when a user wants to delete their post. It is not
|
||||
# particularly secret and does not need to be hashed.
|
||||
user_token = models.CharField(max_length=30, null=True)
|
||||
|
||||
class Meta:
|
||||
permissions = [
|
||||
|
||||
Reference in New Issue
Block a user