From 55b73c69e7faf079642d323985dd48b577615dc6 Mon Sep 17 00:00:00 2001 From: luxagraf Date: Wed, 24 Oct 2018 15:53:37 +0000 Subject: fixed video inserts --- app/photos/models.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'app/photos/models.py') diff --git a/app/photos/models.py b/app/photos/models.py index 9f78ac9..eb4b55e 100644 --- a/app/photos/models.py +++ b/app/photos/models.py @@ -284,7 +284,10 @@ class LuxVideo(models.Model): vimeo_url = models.CharField(null=True, blank=True, max_length=300) def __str__(self): - return self.title + if self.title: + return self.title + else: + return str(self.pk) def get_type(self): return str(self.__class__.__name__) -- cgit v1.2.3-70-g09d2