[webpages] Handle title truncation better
This commit is contained in:
@ -150,8 +150,7 @@ class WebPage(ScrobblableMixin):
|
||||
|
||||
if not self.title and self.extract:
|
||||
first_line = self.extract.split("\n")[0]
|
||||
if len(first_line) < 254:
|
||||
self.title = first_line
|
||||
self.title = first_line[:254]
|
||||
|
||||
if save:
|
||||
self.save(update_fields=["title"])
|
||||
|
||||
Reference in New Issue
Block a user