This website works better with JavaScript.
Home
Help
Sign In
heuzef
/
pinry
mirror of
https://github.com/pinry/pinry.git
Watch
1
Star
0
Fork
0
Code
Issues
0
Releases
44
Wiki
Activity
Browse Source
Fix: Should ignore error caused by pins which reference same image
pull/139/head
winkidney
5 years ago
parent
852cb0b89d
commit
153dc0daef
1 changed files
with
4 additions
and
1 deletions
Split View
Diff Options
Show Stats
Download Patch File
Download Diff File
+4
-1
core/models.py
+ 4
- 1
core/models.py
View File
@@ -89,4 +89,7 @@ class Pin(models.Model):
@receiver(models.signals.post_delete, sender=Pin)
def delete_pin_images(sender, instance, **kwargs):
instance.image.delete()
try:
instance.image.delete()
except Image.DoesNotExist:
pass
Write
Preview
Loading…
Cancel
Save